1 ! Copyright (C) 2010 Joe Groff.
2 ! See http://factorcode.org/license.txt for BSD license.
3 USING: alien.cxx.demangle assocs combinators io.pathnames
4 kernel macho sequences ;
7 : library-symbols ( file -- symbols )
9 { "dylib" [ dylib-exports ] }
10 { f [ dylib-exports ] }
13 : c++-library-symbols ( file abi -- symbols )
14 [ library-symbols ] dip
15 [ '[ _ c++-symbol? ] filter ]
16 [ '[ dup _ demangle ] H{ } map>assoc ] bi ;