Mercurial > hg > Papers > 2021 > anatofuz-master
view paper/src/IsInterface.pm @ 155:6f940582768f
...
author | anatofuz <anatofuz@cr.ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 16 Feb 2021 15:21:11 +0900 |
parents | 88ae1e4d83c6 |
children |
line wrap: on
line source
sub isThisFileInterface { my ($class, $filename) = @_; open my $fh, '<', $filename; my $line = <$fh>; #read top line ex Typedef struct Stack<Type, Impl> { return 0 unless ($line =~ /typedef struct \w+\s?<.*>([\s\w{]+)/); my $annotation = $1; return 0 if ($annotation =~ /impl/); return 1; }