mirror of
https://github.com/c3lang/c3c.git
synced 2026-02-27 20:11:17 +00:00
std::ascii moved into std::core::ascii. Old _m variants are deprecated, as is uint methods.
This commit is contained in:
@@ -1,5 +1,4 @@
|
||||
module std::core::string;
|
||||
import std::ascii;
|
||||
import std::io;
|
||||
|
||||
typedef String @if(!$defined(String)) = inline char[];
|
||||
@@ -787,7 +786,7 @@ macro String.to_integer(self, $Type, int base = 10)
|
||||
usz len = self.len;
|
||||
usz index = 0;
|
||||
char* ptr = self.ptr;
|
||||
while (index < len && ascii::is_blank_m(ptr[index])) index++;
|
||||
while (index < len && ptr[index].is_blank()) index++;
|
||||
if (len == index) return EMPTY_STRING?;
|
||||
bool is_negative;
|
||||
switch (self[index])
|
||||
|
||||
Reference in New Issue
Block a user