mirror of
https://github.com/nemtrif/utfcpp.git
synced 2025-04-06 05:55:08 +00:00
Merge 0bc84a7844
into 67036a031d
This commit is contained in:
commit
fc401fca78
1 changed files with 4 additions and 4 deletions
|
@ -41,7 +41,7 @@ namespace utf8
|
|||
class invalid_code_point : public exception {
|
||||
uint32_t cp;
|
||||
public:
|
||||
invalid_code_point(uint32_t cp) : cp(cp) {}
|
||||
invalid_code_point(uint32_t _cp) : cp(_cp) {}
|
||||
virtual const char* what() const throw() { return "Invalid code point"; }
|
||||
uint32_t code_point() const {return cp;}
|
||||
};
|
||||
|
@ -272,9 +272,9 @@ namespace utf8
|
|||
public:
|
||||
iterator () {}
|
||||
explicit iterator (const octet_iterator& octet_it,
|
||||
const octet_iterator& range_start,
|
||||
const octet_iterator& range_end) :
|
||||
it(octet_it), range_start(range_start), range_end(range_end)
|
||||
const octet_iterator& _range_start,
|
||||
const octet_iterator& _range_end) :
|
||||
it(octet_it), range_start(_range_start), range_end(_range_end)
|
||||
{
|
||||
if (it < range_start || it > range_end)
|
||||
throw std::out_of_range("Invalid utf-8 iterator position");
|
||||
|
|
Loading…
Add table
Reference in a new issue