FAQ

More tests.

Joseph F. Ryan
Nov 23, 2002 at 9:58 am
I've added a slew of new tests to the p6-literals test-suite, including:

- Error tests.
- Bit-type.
- Subscripted variable interpolation.
- Variable method interpolation.
- Many conversion tests.

I was a bit unsure (read: possibly rong as wrabbits) on some of the error
and conversion tests, so let me know if you find any errors or
discrepancies.

Find them at:
http://jryan.perlmonk.org/images/literals.tar.gz
reply

Search Discussions

2 responses

  • Tanton Gibbs at Nov 25, 2002 at 9:02 am
    numbers.t

    comment is wrong
    the first
    #negative big float
    should be
    #negative big int

    string.t

    reverse paired delim qq actually tests reverse paired delim q
    in other words, change
    q)hi(; to qq)hi(; for that test.

    radii.t
    This isn't your fault, but I have to say that 0o0777 looks really bad in my
    font...i.e.
    looks like 000777. Perhaps the powers that be may eliminate octal (who uses
    it?)
    or change it to c? t? or l?

    conversion.t
    The int -> bit conversion doesn't actually convert anything...pehaps you
    meant bit instead of int?
    If you, in fact, did mean bit instead of int, then shouldn't -2 become 1
    instead of 0...I would imagine that anything non-zero would go to 1?

    Also, same applies with num -> bit...no conversions were made.

    interpolation.t

    The Interpolation of Hash as Expressions
    You have %hash.keys interpolating as
    item, two
    I would imagine it would interpolate the same way as an array
    (i.e. item two)

    Also, you test array with non-interpolation, but you don't hash.

    In the $() test, you define x but never use it.

    Also, in the unimplemented & test, I didn't think & was special in a string.
    Instead, I thought
    we should use $() such that
    print "&(noret)"
    should be
    print "$(noret)";

    Is this correct?

    Anyway, it looks good...keep up the good work.

    Tanton
    ----- Original Message -----
    From: "Joseph F. Ryan" <ryan.311@osu.edu>
    To: <perl6-documentation@perl.org>
    Sent: Saturday, November 23, 2002 4:58 AM
    Subject: More tests.

    I've added a slew of new tests to the p6-literals test-suite, including:

    - Error tests.
    - Bit-type.
    - Subscripted variable interpolation.
    - Variable method interpolation.
    - Many conversion tests.

    I was a bit unsure (read: possibly rong as wrabbits) on some of the error
    and conversion tests, so let me know if you find any errors or
    discrepancies.

    Find them at:
    http://jryan.perlmonk.org/images/literals.tar.gz

  • Joseph F. Ryan at Nov 26, 2002 at 1:03 am
    Tanton Gibbs wrote
    radii.t
    This isn't your fault, but I have to say that 0o0777 looks really bad in my
    font...i.e.
    looks like 000777. Perhaps the powers that be may eliminate octal (who uses
    it?)
    or change it to c? t? or l?
    Hmmm, maybe, but 0o00 would be so great in halloween-based JAPHs ;)
    conversion.t
    The int -> bit conversion doesn't actually convert anything...pehaps you
    meant bit instead of int?
    If you, in fact, did mean bit instead of int, then shouldn't -2 become 1
    instead of 0...I would imagine that anything non-zero would go to 1?

    Also, same applies with num -> bit...no conversions were made.

    Right, those are mistakes. Woops :)
    Also, in the unimplemented & test, I didn't think & was special in a string.
    Instead, I thought
    we should use $() such that
    print "&(noret)"
    should be
    print "$(noret)";

    Is this correct?

    Anyway, it looks good...keep up the good work.
    You're right, there is no &(); I'm not even sure how I came up with that...

    I fixed all of the other mistakes you found, thanks.

Related Discussions

Discussion Navigation
viewthread | post

2 users in discussion

Joseph F. Ryan: 2 posts Tanton Gibbs: 1 post