This repository has been archived by the owner on Oct 28, 2021. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
Solidity feature request: macros #2437
Comments
if macros are considered I would suggest something like rust's // This is the simplest macro, `say_hello` is the name of the macro
macro_rules! say_hello {
// `()` indicates that the macro takes no argument
() => (
// the macro will expand into the contents of this block
println!("Hello!");
)
} |
Yes, I would also prefer a token-based macro system like the one used by rust. |
+1 for native macros instead of preprocessor based. Rust's macros are not particularly nice though, we could do better. |
chriseth
changed the title
Solc feature request: macros
Solidity feature request: macros
Jul 14, 2015
This issue has been moved to ethereum/solidity repository |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
I want this:
and so on. Don't tell me it's unsafe, I'm gonna use gcc to do it if you don't!
The text was updated successfully, but these errors were encountered: