Source/NFX.Erlang/ErlInputStream.cs
/// <summary>
/// Read Erlang list from the stream
/// </summary>
Read Erlang list from the stream
Read Erlang list from the stream
public ErlList ReadList()
      {
        int arity = readListHead();
        if (arity == 0)
          return new ErlList();
        var list = new List<IErlObject>(arity);
        for (int i = 0; i < arity; i++)
          list.Add(Read());
        var next = Peek();
        if (next.Item1 && (ErlExternalTag)next.Item2 == ErlExternalTag.Nil)
          readTag(ErlExternalTag.Nil);
        return new ErlList(list, false);
      }
public ErlList ReadList ( ) { int arity = readListHead ( ) ; if ( arity == 0 ) return new ErlList ( ) ; var list = new List < IErlObject > ( arity ) ; for ( int i = 0 ; i < arity ; i ++ ) list . Add ( Read ( ) ) ; var next = Peek ( ) ; if ( next . Item1 && ( ErlExternalTag ) next . Item2 == ErlExternalTag . Nil ) readTag ( ErlExternalTag . Nil ) ; return new ErlList ( list , false ) ; }
Read Erlang list from the stream
Read Erlang list from the stream