MCPcopy Create free account
hub / github.com/facebook/chisel / _dataIsString

Function _dataIsString

commands/FBVisualizationCommands.py:169–180  ·  view source on GitHub ↗
(data)

Source from the content-addressed store, hash-verified

167
168
169def _dataIsString(data):
170 data = "(" + data + ")"
171
172 result = fb.evaluateExpressionValue(
173 "(NSString*)[[NSString alloc] initWithData:" + data + " encoding:4]"
174 )
175
176 if result.GetError() is not None and str(result.GetError()) != "success":
177 return False
178 else:
179 isString = result.GetValueAsUnsigned() != 0
180 return isString
181
182
183def _visualize(target):

Callers 1

_visualizeFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected