BIND 10 #2374: MasterLexer's Number state classes

BIND 10 Development do-not-reply at isc.org
Sun Nov 25 20:22:42 UTC 2012


#2374: MasterLexer's Number state classes
-------------------------------------+-------------------------------------
                   Reporter:         |                 Owner:  jelte
  jinmei                             |                Status:  reviewing
                       Type:  task   |             Milestone:
                   Priority:         |  Sprint-20121204
  medium                             |            Resolution:
                  Component:         |             Sensitive:  0
  libdns++                           |           Sub-Project:  DNS
                   Keywords:         |  Estimated Difficulty:  4
            Defect Severity:  N/A    |           Total Hours:  0
Feature Depending on Ticket:         |
  loadzone-ng                        |
        Add Hours to Ticket:  0      |
                  Internal?:  0      |
-------------------------------------+-------------------------------------
Changes (by muks):

 * owner:  muks => jelte


Comment:

 Hi Jelte

 Here are my review comments.

 * What happens if the lexer is at `"1234;my_comment"` (without quotes)? Is
 it parsed as a number?

 * Please add tests for the escaped cases.

 * `strtoul()` accepts a signed `int` type for base, so its type should be
 updated.

 * Can we add this comment to `master_lexer.cc`:
 {{{
 +++ b/src/lib/dns/master_lexer.cc
 @@ -252,7 +252,7 @@ const CRLF CRLF_STATE;
  const String STRING_STATE;
  const QString QSTRING_STATE;
  const Number NUMBER_STATE;
 -}
 +} // unnamed namespace
 }}}

 * This is the first time I'm looking at the string and number lexers.
 Though it is offtopic to this bug, I think the string tests in some places
 miss comparing the token's values such as in `MasterLexerStateTest.crlf`
 (from basic checking, the code it's testing is correct though).

 * Is there a ticket to handle the `\DDD` syntax (RFC1035 sec 5.1)?

-- 
Ticket URL: <http://bind10.isc.org/ticket/2374#comment:7>
BIND 10 Development <http://bind10.isc.org>
BIND 10 Development


More information about the bind10-tickets mailing list