react-native/Libraries/Utilities
Peter Janak de8a370e02 Fixing jsdoc parsing of functions that are defined over multiple lines (Fixes #410)
Summary:
As it was implemented, the jsdoc parser would look only the first non-blank line immediately preceding a function declaration. However, the line that was set as the beginning of a function declaration was where the opening bracket (`{`) was. This is insufficient for functions whose definitions span multiple lines. For example, this declaration would not find the comments above it:

```
/**
 * Clones rows
 **/
cloneWithRows(
       dataBlob: Array<any> | {[key: string]: any},
       rowIdentities: ?Array<string>
   ): ListViewDataSource {
...
}
```

With this change, the parser will first check if we have a closing parenthesis. If we do and don't have a matching open parenthesis we continue moving up the lines until we find it. Then we set previous line to be the line before that, the true beginning of the function declaration.
Closes https://github.com/facebook/react-native/pull/360
Github Author: Peter Janak <pjanak@nhl.com>

Test Plan: Run the website
2015-04-04 09:56:16 -08:00
..
differ Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
AlertIOS.js Fixing jsdoc parsing of functions that are defined over multiple lines (Fixes #410) 2015-04-04 09:56:16 -08:00
Backstack.ios.js [ReactNative] OSS JSNavigationStack w/ Examples 2015-03-24 09:39:40 -08:00
CSSVarConfig.js [ReactNative] OSS JSNavigationStack w/ Examples 2015-03-24 09:39:40 -08:00
Dimensions.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
ErrorUtils.js [ReactNative] Expanded license on js files 2015-03-23 13:17:54 -08:00
MessageQueue.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
PixelRatio.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
Platform.ios.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
RCTLog.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
RCTRenderingPerf.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
buildStyleInterpolator.js [ReactNative] OSS JSNavigationStack w/ Examples 2015-03-24 09:39:40 -08:00
createStrictShapeTypeChecker.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
cssVar.js [ReactNative] OSS JSNavigationStack w/ Examples 2015-03-24 09:39:40 -08:00
deepFreezeAndThrowOnMutationInDev.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
groupByEveryN.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
logError.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
mergeFast.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
mergeIntoFast.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
nativeModulePrefixNormalizer.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00
truncate.js Flowify Library/Utilities/ 2015-03-23 16:47:26 -08:00