More robust regex for stack frames
Summary: - Library name can contain whitespace and dots. - Not using fixed number of whitespace characters. Reviewed By: fabiomassimo Differential Revision: D21185820 fbshipit-source-id: 429656dc03b6450ef61383ed91b5aee132802ca8
This commit is contained in:
committed by
Facebook GitHub Bot
parent
f5ed06cbd7
commit
8936ec540c
@@ -12,7 +12,7 @@ import {colors, StackTrace} from 'flipper';
|
||||
|
||||
const FacebookLibraries = ['Facebook'];
|
||||
|
||||
const REGEX = /(?<library>\w*) *(?<address>0x\w*) (?<caller>(.*)) \\+ (?<lineNumber>\d*)/;
|
||||
const REGEX = /\d+\s+(?<library>(\s|\w|\.)+\w)\s+(?<address>0x\w+?)\s+(?<caller>.+) \+ (?<lineNumber>\d+)/;
|
||||
|
||||
function isSystemLibrary(libraryName: ?string): boolean {
|
||||
return !FacebookLibraries.includes(libraryName);
|
||||
|
||||
Reference in New Issue
Block a user