Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » Community » U++ community news and announcements » String & strlen optimization, force_inline in defs.h
Re: String & strlen optimization, force_inline in defs.h [message #34638 is a reply to message #34620] Fri, 02 December 2011 19:57 Go to previous message
Novo is currently offline  Novo
Messages: 1430
Registered: December 2006
Ultimate Contributor
Another trick:

template <int N> 
int strlen__(const char (&s)[N]) { return N; }

Cout() << strlen__("asdf") << EOL;


Regards,
Novo
 
Read Message
Read Message
Previous Topic: svn and redmine urls
Next Topic: Sql: New 'Of' 'syntax'
Goto Forum:
  


Current Time: Tue Jul 15 06:29:07 CEST 2025

Total time taken to generate the page: 0.03535 seconds