Does STVD suport static inline key to declare function?
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2009-04-24 4:31 AM
Posted on April 24, 2009 at 13:31
Does STVD suport static inline key to declare function?
This discussion is locked. Please start a new topic to ask your question.
5 REPLIES 5
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2011-05-17 6:02 AM
Posted on May 17, 2011 at 15:02
Hello
''static inline'' key to declare function have error in STVD. I know GCC suport ''static inline'', Then STVD? Redards wolverOptions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2011-05-17 6:02 AM
Posted on May 17, 2011 at 15:02
Hi wolver,
I think this is related to the compiler: With cosmic compiler you can do this by the directive @inline With raisonnance compiler you can check the compiler option ''SPEED optimization'' and the compiler do this automatically Regards mozraOptions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2011-05-17 6:02 AM
Posted on May 17, 2011 at 15:02just out of curiosity: why would you want to inline functions ?
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2011-05-17 6:02 AM
Posted on May 17, 2011 at 15:02
Hi mozra
I use STM8 Cosmic, not raisonnance. But I should try to do it by the directive @inline ... Regards wolverOptions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
‎2011-05-17 6:02 AM
Posted on May 17, 2011 at 15:02
Hi _luca
We have some short fuctions, such as following... If ''static inline'' can be used, The compiler obj has not push-pop stack. Regards wolver PS: some short fuctions... void ModifyCurSystemStatus(unsigned char current_status) { g_ucSystemCurStatus = current_status; } unsigned char GetCurSystemStatus(void) { return g_ucSystemCurStatus; } void load_timer3_value(void) { TIM3_CNTRH = 0x1E; TIM3_CNTRL = 0xFF; }