Click here to Skip to main content
15,791,891 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: How can i draw the curve shape of mountains in terrain of game? Pin
Noor Akhter13-Jul-06 9:59
Noor Akhter13-Jul-06 9:59 
GeneralRe: How can i draw the curve shape of mountains in terrain of game? Pin
FarPointer13-Jul-06 10:08
FarPointer13-Jul-06 10:08 
GeneralRe: How can i draw the curve shape of mountains in terrain of game? Pin
earl13-Jul-06 12:45
earl13-Jul-06 12:45 
GeneralRe: How can i draw the curve shape of mountains in terrain of game? Pin
Panic2k313-Jul-06 18:21
Panic2k313-Jul-06 18:21 
QuestionC++ code parser... Pin
Nitron13-Jul-06 9:39
Nitron13-Jul-06 9:39 
AnswerRe: C++ code parser... Pin
earl13-Jul-06 12:46
earl13-Jul-06 12:46 
GeneralRe: C++ code parser... Pin
Nitron13-Jul-06 15:42
Nitron13-Jul-06 15:42 
GeneralRe: C++ code parser... Pin
earl13-Jul-06 20:15
earl13-Jul-06 20:15 
Man, that's not a trivial thing to do.

To start you'll need a lexer -- takes text and determines if it's valid C++. This alone takes some doing, cause C++ isn't the most syntactically pretty language around. Don't try and do it yourself or you'll die of old age; instead, write a grammer and lean on a lexer.

Then you'll need a parser; it takes the output from a lexer and typically gives you a structure tree.

Grab the dragon book and read about compiler construction; you're building the first two or three stages of one.

For available tools, try lex, yacc, and bison.

earl
AnswerRe: C++ code parser... Pin
Taka Muraoka13-Jul-06 17:14
Taka Muraoka13-Jul-06 17:14 
Questionsorting a list Pin
aafcls13-Jul-06 9:20
aafcls13-Jul-06 9:20 
AnswerRe: sorting a list Pin
FarPointer13-Jul-06 9:45
FarPointer13-Jul-06 9:45 
AnswerRe: sorting a list Pin
Zac Howland13-Jul-06 9:48
Zac Howland13-Jul-06 9:48 
AnswerRe: sorting a list Pin
David Crow13-Jul-06 9:52
David Crow13-Jul-06 9:52 
GeneralRe: sorting a list Pin
aafcls13-Jul-06 10:06
aafcls13-Jul-06 10:06 
GeneralRe: sorting a list Pin
FarPointer13-Jul-06 10:10
FarPointer13-Jul-06 10:10 
GeneralRe: sorting a list Pin
David Crow13-Jul-06 10:13
David Crow13-Jul-06 10:13 
GeneralRe: sorting a list Pin
FarPointer13-Jul-06 10:27
FarPointer13-Jul-06 10:27 
QuestionRe: sorting a list Pin
David Crow13-Jul-06 10:30
David Crow13-Jul-06 10:30 
AnswerRe: sorting a list Pin
FarPointer13-Jul-06 10:35
FarPointer13-Jul-06 10:35 
QuestionRe: sorting a list Pin
David Crow13-Jul-06 10:44
David Crow13-Jul-06 10:44 
AnswerRe: sorting a list Pin
FarPointer13-Jul-06 10:49
FarPointer13-Jul-06 10:49 
GeneralRe: sorting a list Pin
aafcls13-Jul-06 10:52
aafcls13-Jul-06 10:52 
GeneralRe: sorting a list Pin
David Crow13-Jul-06 11:02
David Crow13-Jul-06 11:02 
GeneralRe: sorting a list Pin
aafcls13-Jul-06 11:05
aafcls13-Jul-06 11:05 
GeneralRe: sorting a list Pin
David Crow13-Jul-06 11:14
David Crow13-Jul-06 11:14 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.