Last change
on this file since 797 was 622, checked in by dai_9181, 16 years ago |
ResourceManagerクラスを追加。既存のリソース管理モジュールの置き換えを行った。
|
File size:
439 bytes
|
Rev | Line | |
---|
[622] | 1 | #include "stdafx.h"
|
---|
| 2 |
|
---|
| 3 | std::string Jenga::Common::EasyToken::GetIdentifierToken( const std::string &source, int &sourceIndex )
|
---|
| 4 | {
|
---|
| 5 | char *token = (char *)malloc( source.size() + 1 );
|
---|
| 6 |
|
---|
| 7 | for( int i=0; ; i++, sourceIndex++ )
|
---|
| 8 | {
|
---|
| 9 | if( ! IsIdentifierChar( source[sourceIndex] ) )
|
---|
| 10 | {
|
---|
| 11 | token[i] = 0;
|
---|
| 12 | break;
|
---|
| 13 | }
|
---|
| 14 | token[i] = source[sourceIndex];
|
---|
| 15 | }
|
---|
| 16 |
|
---|
| 17 | std::string resultToken = token;
|
---|
| 18 | free( token );
|
---|
| 19 |
|
---|
| 20 | return resultToken;
|
---|
| 21 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.