compiler-explorer / asm-parser

BSD 2-Clause "Simplified" License
27 stars 7 forks source link

Hint #22

Closed hanickadot closed 2 years ago

hanickadot commented 2 years ago

Hi @mattgodbolt told me about you using CTRE here, I read the code and noticed this:

https://github.com/compiler-explorer/asm-parser/blob/74f51e4f21810931531a80f17a7a6e00fb56a894/src/utils/regexwrappers.cpp#L20-L21

You can use .to_number<T>() on capture group :)

hanickadot commented 2 years ago

match.to_number() (int is default)

mattgodbolt commented 2 years ago

That's awesome! Thanks @hanickadot !