File: make_mli

package info (click to toggle)
coq 8.0pl2-2
  • links: PTS
  • area: main
  • in suites: sarge
  • size: 14,228 kB
  • ctags: 17,685
  • sloc: ml: 97,070; makefile: 1,255; sh: 738; lisp: 456; awk: 15
file content (17 lines) | stat: -rwxr-xr-x 382 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#!/usr/bin/awk -We $0

{ match($0,"^open") 
  if (RLENGTH>0) state=1
  match($0,"^type") 
  if (RLENGTH>0) state=1 
  match($0,"^\(\*\* ")
  if (RLENGTH>0) state=2
  match($0,"^let")
  if (RLENGTH>0) state=0
  match($0,"^and")
  if ((RLENGTH>0) && (state==2)) state=0
  if ((RLENGTH>0) && (state==1)) state=1		     
  gsub("\(\*\* ","")
  gsub("\*\*\)","")
  if (state>0) print
}