Show More
@@ -902,17 +902,17 b' def main(argv=None):' | |||
|
902 | 902 | |
|
903 | 903 | optstart = 2 |
|
904 | 904 | displayargs['function'] = None |
|
905 | if argv[1] == 'hotpath': | |
|
905 | if argv[1] == r'hotpath': | |
|
906 | 906 | displayargs['format'] = DisplayFormats.Hotpath |
|
907 | elif argv[1] == 'lines': | |
|
907 | elif argv[1] == r'lines': | |
|
908 | 908 | displayargs['format'] = DisplayFormats.ByLine |
|
909 | elif argv[1] == 'functions': | |
|
909 | elif argv[1] == r'functions': | |
|
910 | 910 | displayargs['format'] = DisplayFormats.ByMethod |
|
911 | elif argv[1] == 'function': | |
|
911 | elif argv[1] == r'function': | |
|
912 | 912 | displayargs['format'] = DisplayFormats.AboutMethod |
|
913 | 913 | displayargs['function'] = argv[2] |
|
914 | 914 | optstart = 3 |
|
915 | elif argv[1] == 'flame': | |
|
915 | elif argv[1] == r'flame': | |
|
916 | 916 | displayargs['format'] = DisplayFormats.FlameGraph |
|
917 | 917 | else: |
|
918 | 918 | printusage() |
@@ -930,22 +930,22 b' def main(argv=None):' | |||
|
930 | 930 | displayargs['limit'] = 0.05 |
|
931 | 931 | path = None |
|
932 | 932 | for o, value in opts: |
|
933 | if o in ("-l", "--limit"): | |
|
933 | if o in (r"-l", r"--limit"): | |
|
934 | 934 | displayargs['limit'] = float(value) |
|
935 | elif o in ("-f", "--file"): | |
|
935 | elif o in (r"-f", r"--file"): | |
|
936 | 936 | path = value |
|
937 | elif o in ("-o", "--output-file"): | |
|
937 | elif o in (r"-o", r"--output-file"): | |
|
938 | 938 | displayargs['outputfile'] = value |
|
939 | elif o in ("-p", "--script-path"): | |
|
939 | elif o in (r"-p", r"--script-path"): | |
|
940 | 940 | displayargs['scriptpath'] = value |
|
941 | elif o in ("-h", "help"): | |
|
941 | elif o in (r"-h", r"help"): | |
|
942 | 942 | printusage() |
|
943 | 943 | return 0 |
|
944 | 944 | else: |
|
945 | 945 | assert False, "unhandled option %s" % o |
|
946 | 946 | |
|
947 | 947 | if not path: |
|
948 | print('must specify --file to load') | |
|
948 | print(r'must specify --file to load') | |
|
949 | 949 | return 1 |
|
950 | 950 | |
|
951 | 951 | load_data(path=path) |
@@ -954,5 +954,5 b' def main(argv=None):' | |||
|
954 | 954 | |
|
955 | 955 | return 0 |
|
956 | 956 | |
|
957 | if __name__ == "__main__": | |
|
957 | if __name__ == r"__main__": | |
|
958 | 958 | sys.exit(main()) |
General Comments 0
You need to be logged in to leave comments.
Login now