Ignore:
Timestamp:
Mar 29, 2014, 4:39:19 PM (4 years ago)
Author:
ksherdy
Message:

Replaced function keyword with filter.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • proto/s2k/trunk/framework/input/test/s2k/test.s2k

    r3762 r3767  
    3232};
    3333
    34 function ClassifyBytes(struct Basis_bits basis_bits, struct Lex lex) {
     34filter ClassifyBytes(struct Basis_bits basis_bits, struct Lex lex) {
    3535    stream temp1 = (basis_bits.bit_1 & (~ basis_bits.bit_0));
    3636    stream temp2 = (basis_bits.bit_2 & (~ basis_bits.bit_3));
     
    6060}
    6161
    62 function Match(struct Lex lex, struct Matches matches) {
     62filter Match(struct Lex lex, struct Matches matches) {
    6363    stream m0 = lex.a;
    6464    stream m1 = (pablo.Advance(m0) & lex.p);
     
    6969}
    7070
    71 function MatchLines1(struct Lex lex, struct Matches matches, struct Lines lines) {
     71filter MatchLines1(struct Lex lex, struct Matches matches, struct Lines lines) {
    7272    stream last_start = pablo.First();
    7373    stream LF_or_match = (lex.LF | matches.all_matched);
     
    8686}
    8787
    88 function MatchLines2(struct Lex lex, struct Matches matches, struct Lines lines) {
     88filter MatchLines2(struct Lex lex, struct Matches matches, struct Lines lines) {
    8989    stream last_start = pablo.Mask(1,0);
    9090    last_start = (pablo.Advance((~ last_start)) ^ (~ last_start));
     
    104104}
    105105
    106 function FilterMatchLines(struct Data data, struct Output output) {
     106filter nameMatchLines(struct Data data, struct Output output) {
    107107    output.lines = pablo.filter_bytes(data, (~ lines.all_matched));
    108108}
    109109
    110 function CountLines(struct Lex lex, struct Lines lines) {
     110filter CountLines(struct Lex lex, struct Lines lines) {
    111111    return pablo.PopCount((pablo.MatchStar(lines, (~ lex.LF)) & lex.LF)) ;
    112112}
Note: See TracChangeset for help on using the changeset viewer.