Skip to content

More ternary op failures #119

Description

@mkaput

The following tests are failing even after #115. I won't have time to investigate them further.

    test "ellipsis does not continue across semicolon-separated // forms" do
      assert Spitfire.parse("x...\n;//y") == s2q("x...\n;//y")
      assert Spitfire.parse("x...\n;\n//y") == s2q("x...\n;\n//y")
      assert Spitfire.parse("x...\n;\n# comment\n//y") == s2q("x...\n;\n# comment\n//y")
    end

    test "parenthesized //(do-end) keeps following when outside slash rhs" do
      assert Spitfire.parse("//(foo do :ok end) when x") == s2q("//(foo do :ok end) when x")
      assert Spitfire.parse("//(foo do :ok end)\nwhen x") == s2q("//(foo do :ok end)\nwhen x")
    end

    test "parenthesized //(do-end) keeps following <- outside slash rhs" do
      assert Spitfire.parse("//(foo do :ok end) <- x") == s2q("//(foo do :ok end) <- x")
      assert Spitfire.parse("//(foo do :ok end)\n<- x") == s2q("//(foo do :ok end)\n<- x")
    end

    test "parenthesized //(do-end) keeps following :: outside slash rhs" do
      assert Spitfire.parse("//(foo do :ok end) :: x") == s2q("//(foo do :ok end) :: x")
      assert Spitfire.parse("//(foo do :ok end)\n:: x") == s2q("//(foo do :ok end)\n:: x")
    end

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions