21 points | by todsacerdoti 6 days ago ago
3 comments
shame we dont do more cool stuff with builtins. so many times ive wished for something like
__builtin_regex_compile() __builtin_regex_match()
regexes don't generally belong as compiler builtins. Those are more suitable for language standard libraries or OS standards like POSIX.
If there were an ISA out there that had some kind of regular expression feature, those could conceivably be supported with builtins, though.
https://pubs.opengroup.org/onlinepubs/009696899/functions/re...
I wonder how one would do DFA minimization with that though. Implement regexp functional equivalence testing so I will not have to! :D
shame we dont do more cool stuff with builtins. so many times ive wished for something like
__builtin_regex_compile() __builtin_regex_match()
regexes don't generally belong as compiler builtins. Those are more suitable for language standard libraries or OS standards like POSIX.
If there were an ISA out there that had some kind of regular expression feature, those could conceivably be supported with builtins, though.
https://pubs.opengroup.org/onlinepubs/009696899/functions/re...
I wonder how one would do DFA minimization with that though. Implement regexp functional equivalence testing so I will not have to! :D