Code::Blocks Forums
Welcome,
Guest
. Please
login
or
register
.
Did you miss your
activation email
?
1 Hour
1 Day
1 Week
1 Month
Forever
Login with username, password and session length
News:
As usual while waiting for the next release - don't forget to check the
nightly builds
in the forum.
Home
Help
Search
Login
Register
Code::Blocks Forums
»
User forums
»
Using Code::Blocks
»
what is the purpose of //(* //*) symbol pattern
« previous
next »
Send this topic
Print
Pages: [
1
]
Go Down
Author
Topic: what is the purpose of //(* //*) symbol pattern (Read 3370 times)
almonj
Single posting newcomer
Posts: 2
what is the purpose of //(* //*) symbol pattern
«
on:
January 05, 2017, 06:58:38 pm »
I'm programming a wxWidgets project in code blocks and it inserts the symbol pattern //(* //*) in a bunch of places and I don't understand what this does.
eg.
//(*IdInit(wxfileDialog)
const long wxfileDialog::ID_STATICTEXT1 = wxNewId();
const long wxfileDialog::ID_BUTTON3 = wxNewId();
const long wxfileDialog::ID_BUTTON1 = wxNewId();
const long wxfileDialog::ID_BUTTON2 = wxNewId();
const long wxfileDialog::ID_STATICLINE1 = wxNewId();
//*)
it looks like some kind of commenting thing but the code inside is functional. What is the purpose of this?
[/size][/font][/b]
Logged
stahta01
Lives here!
Posts: 7791
Re: what is the purpose of //(* //*) symbol pattern
«
Reply #1 on:
January 05, 2017, 07:15:28 pm »
This is auto generated wxSmith code; the comments tell you NOT to edit code inside this block of code.
Edit: I do NOT use wxSmith myself; so, this is based on what I remember from past posts, I might be wrong.
Tim S.
«
Last Edit: January 05, 2017, 08:05:45 pm by stahta01
»
Logged
C Programmer working to learn more about C++ and Git.
On Windows 10 64 bit and Windows 11 64 bit.
--
When in doubt, read the CB WiKi FAQ.
http://wiki.codeblocks.org
oBFusCATed
Developer
Lives here!
Posts: 13406
Re: what is the purpose of //(* //*) symbol pattern
«
Reply #2 on:
January 05, 2017, 08:18:09 pm »
//(* and //*) are single line comments they are not the same as /* and */. So the code between them is not commented out, but it is fully functional. wxSmith uses these comments to find section where to write its code.
Logged
(most of the time I ignore long posts)
[strangers don't send me private messages, I'll ignore them; post a topic in the forum, but first read the rules!]
Send this topic
Print
Pages: [
1
]
Go Up
« previous
next »
Code::Blocks Forums
»
User forums
»
Using Code::Blocks
»
what is the purpose of //(* //*) symbol pattern