jack (
jack
) wrote
in
simont
2019-03-09 11:26 am (UTC)
Everybody stand back, I know inadvisable preprocessor tricks!
#define max(a,b) (a>b?a:b)
Works, right? If both arguments are l-values, you can assign to it. If either isn't, you can't. Obviously with all the usual reasons why you don't use a define for that. But it doesn't work with a function?
(
12 comments
)
Post a comment in response:
From:
Anonymous
This account has disabled anonymous posting.
OpenID
Identity URL:
Log in?
Dreamwidth account
Account name
Password
Log in?
If you don't have an account you can
create one now
.
Subject
HTML doesn't work in the subject.
Formatting type
Casual HTML
Markdown
Raw HTML
Rich Text Editor
Message
[
Home
|
Post Entry
|
Log in
|
Search
|
Browse Options
|
Site Map
]
Everybody stand back, I know inadvisable preprocessor tricks!
Works, right? If both arguments are l-values, you can assign to it. If either isn't, you can't. Obviously with all the usual reasons why you don't use a define for that. But it doesn't work with a function?