100+ results for 'var result repo:duckduckgo/zeroclickinfo-spice'

Not the results you expected?

TestNumericTraitsComplex.h (https://bitbucket.org/sonofusion/.simulation.git) C Header · 463 lines

226 base_type a4 = tvmet::NumericTraits<T>::abs(m_z4);

227

228 // result depends on signed type

229 AbsHelper(tvmet::dispatch<is_signed>(), a1);

230 AbsHelper(tvmet::dispatch<is_signed>(), a2);

334 base_type n4 = tvmet::NumericTraits<T>::norm_1(m_z4);

335

336 // result depends on signed type

337 NormHelper(tvmet::dispatch<is_signed>(), n1);

338 NormHelper(tvmet::dispatch<is_signed>(), n2);

358 base_type n4 = tvmet::NumericTraits<T>::norm_2(m_z4);

359

360 // result depends on signed type

361 NormHelper(tvmet::dispatch<is_signed>(), n1);

362 NormHelper(tvmet::dispatch<is_signed>(), n2);

properties.cpp (https://gitlab.com/brian0218/rk3188_r-box_android4.2.2_sdk) C++ · 340 lines

15 //

16 // \file

17 // Functions for updating property bits for various FST operations and

18 // string names of the properties.

19

25

26 // These functions determine the properties associated with the FST

27 // result of various finite-state operations. The property arguments

28 // correspond to the operation's FST arguments. The properties

29 // returned assume the operation modifies its first argument.

30 // Bitwise-and this result with kCopyProperties for the case when a

31 // new (possibly delayed) FST is instead constructed.

32

When_comparing_HtmlNodes_for_equality.cs (https://bitbucket.org/mchudo89/webpack-2.0.git) C# · 164 lines

30

31 // Act

32 bool result = comparer.Equals(node1, node2);

33

34 // Assert

35 Assert.True(result);

36 }

37

49

50 // Act

51 bool result = comparer.Equals(node1, node2);

52

53 // Assert

aping-plugin-rss.js (https://gitlab.com/Mirros/jsdelivr) JavaScript · 175 lines

95

96 this.getObjectByJsonData = function (_data, _helperObject) {

97 var requestResults = [];

98 if (_data && _data.data && _data.data.responseData) {

99 if (_data.data.responseData.feed && _data.data.responseData.feed.entries) {

100

101 var _this = this;

102

103 angular.forEach(_data.data.responseData.feed.entries, function (value, key) {

104 var tempResult;

105 if (_helperObject.getNativeData === true || _helperObject.getNativeData === "true") {

106 tempResult = value;

114 if (tempResult) {

115 requestResults.push(tempResult);

116 }

117 });

columntoggle_option_core.js (https://github.com/gabrielschulhof/jquery-mobile.git) JavaScript · 190 lines

7

8 function getSwatchClasses( element, prefix ) {

9 var index,

10 list = element.className.split( " " ),

11 resultList = [],

14 for ( index in list ) {

15 if ( list[ index ].match( regex ) ) {

16 resultList.push( list[ index ] );

17 }

18 }

19

20 return resultList;

21 }

22

SingularField.java (https://gitlab.com/essere.lab.public/qualitas.class-corpus) Java · 148 lines

21 import net.sourceforge.pmd.ast.ASTStatementExpression;

22 import net.sourceforge.pmd.ast.ASTSynchronizedStatement;

23 import net.sourceforge.pmd.ast.ASTVariableDeclaratorId;

24 import net.sourceforge.pmd.ast.Node;

25 import net.sourceforge.pmd.ast.SimpleNode;

34

35 /**

36 * Restore old behaviour by setting both properties to true, which will result in many false positives

37 */

38 private static final PropertyDescriptor CHECK_INNER_CLASSES = new BooleanProperty(

46

47 if (node.isPrivate() && !node.isStatic()) {

48 List<ASTVariableDeclaratorId> list = node.findChildrenOfType(ASTVariableDeclaratorId.class);

49 ASTVariableDeclaratorId declaration = list.get(0);

CodeGenerationUtils.java (https://gitlab.com/essere.lab.public/qualitas.class-corpus) Java · 140 lines

103 if (cls != null) {

104 String clsName = cls.getName().toString();

105 String clsVarName =

106 Character.toLowerCase(clsName.charAt(0))

107 + clsName.substring(1);

108 clsVarName = (clsVarName.equals(clsName)) ? '_' + clsVarName : clsVarName; // NOI18N

109 functionCall.append(" ") // NOI18N

110 .append(cls.getQualifiedName()) // NOI18N

111 .append(" ") // NOI18N

112 .append(clsVarName); // NOI18N

113 if (!CsmKindUtilities.isConstructor(method)) {

114 functionCall.append(";\n"); // NOI18N

woocommerce-update-2.2.php (https://gitlab.com/webkod3r/tripolis) PHP · 196 lines

114 // Update variations which manage stock

115 $update_variations = $wpdb->get_results( "

116 SELECT DISTINCT posts.ID AS variation_id, posts.post_parent AS variation_parent FROM {$wpdb->posts} as posts

117 LEFT OUTER JOIN {$wpdb->postmeta} AS postmeta ON posts.ID = postmeta.post_id AND postmeta.meta_key = '_stock'

118 LEFT OUTER JOIN {$wpdb->postmeta} as postmeta2 ON posts.ID = postmeta2.post_id AND postmeta2.meta_key = '_manage_stock'

119 WHERE posts.post_type = 'product_variation'

120 AND postmeta.meta_value IS NOT NULL

121 AND postmeta.meta_value != ''

123 " );

124

125 foreach ( $update_variations as $variation ) {

126 $parent_backorders = get_post_meta( $variation->variation_parent, '_backorders', true );

127 add_post_meta( $variation->variation_id, '_manage_stock', 'yes', true );

128 add_post_meta( $variation->variation_id, '_backorders', $parent_backorders ? $parent_backorders : 'no', true );

playsheet.js (https://gitlab.com/gramie/dotlog) JavaScript · 177 lines

100 var rowclass = (i % 2 == 0) ? 'even' : 'odd';

101 var Result = '<tr class="' + rowclass + '">';

102 var entryTime = getDrupalFormTime('start') + parseInt(row.startMinutes);

113 + '<td>' + row.language + '</td>';

114 if (playsheetEditable) {

115 Result += '<td><div class="playsheet-buttons">';

116 Result += '<button type="button" onclick="editPlaysheetEntry(' + i + ');" title="Edit entry">&#9998;</button>';

117 Result += '<button type="button" onclick="deletePlaysheetEntry(' + i + ');" title="Delete entry"><span style="color:red;">&#10007;</span></button>';

118 if (i > 0) {

119 Result += '<button type="button" onclick="moveEntry(' + i + ', -1);" title="Move up one row">&#8593;</button>';

167 var result = parseInt(parts[0]) * 60 + parseInt(parts[1]);

168 } else {

169 var result = parseInt(timestring, 10);

170 }

171 return (result);

test051.tcl (https://gitlab.com/OpenSourceMirror/sourcenav) TCL · 221 lines

7 # TEST test051

8 # TEST Fixed-length record Recno test.

9 # TEST 0. Test various flags (legal and illegal) to open

10 # TEST 1. Test partial puts where dlen != size (should fail)

11 # TEST 2. Partial puts for existent record -- replaces at beg, mid, and

50 set oflags "-create -mode 0644 $args"

51

52 # Test various flags (legal and illegal) to open

53 puts "\tTest051.a: Test correct flag behavior on open."

54 set errorCode NONE

104

105 # We don't get back the server error string just

106 # the result.

107 if { $eindex == -1 } {

108 error_check_good "dbput:partial: dlen < size" \

Stock.php (https://gitlab.com/staging06/myproject) PHP · 180 lines

32 class StockCore extends ObjectModel

33 {

34 /** @var int identifier of the warehouse */

35 public $id_warehouse;

36

37 /** @var int identifier of the product */

38 public $id_product;

39

176 WHERE `id_warehouse` = '.(int)$id_warehouse.' AND `id_product` = '.(int)$id_product.((int)$id_product_attribute ? ' AND `id_product_attribute` = '.$id_product_attribute : ''));

177

178 return (is_array($result) && !empty($result) ? true : false);

179 }

180 }

base-observable-debug.js (https://gitlab.com/Blueprint-Marketing/cdnjs) JavaScript · 209 lines

8 @submodule base-observable

9 **/

10 var L = Y.Lang,

11

12 DESTROY = "destroy",

83 // critical path performance

84

85 var type = this._getFullType(INIT),

86 e = this._publish(type);

87

117 }

118

119 var i, l, target,

120 userTargets = (config && BUBBLETARGETS in config);

121

folders-abstract.js (https://gitlab.com/aparle/golf2016Android) JavaScript · 161 lines

19 function (fe) {

20 fe.file(function (f) {

21 var r = new FileReader();

22 r.onloadend = function () {

23 if ($.isFunction(successCallback)) {

24 successCallback(JSON.parse(this.result));

25 }

26 };

41 },

42 retrieveFolderData: function (callback) {

43 var self = this,

44 createNew = function () {

45 self.addNewFolder("Folder 1");

ConverterUtils.java (https://bitbucket.org/haris_peco/debrief.git) Java · 192 lines

58 * @return The updated list.

59 */

60 protected static List<VariantInfo> addVariant(List<VariantInfo> variants,

61 VariantInfo variant) {

96 // Loop over the variants list

97 for (VariantInfo helperVariant : helperVariants) {

98 if (targetVariant == null) {

99 result = addVariant(result, helperVariant);

100 } else if (helperVariant.includes(targetVariant)) {

102 // the conversion is possible to the target variant.

103 result = addVariant(result, new VariantInfo(

104 targetVariant.getMediaType()));

107 // the conversion is possible to the target variant.

108 result = addVariant(result, helperVariant);

109 }

110 }

RegisterAllocator.java (https://gitlab.com/brian0218/rk3188_r-box_android4.2.2_sdk) Java · 197 lines

86 return 1;

87 } else {

88 return definition.getResult().getCategory();

89 }

90 }

100 SsaInsn definition = ssaMeth.getDefinitionForRegister(reg);

101

102 return definition == null ? null : definition.getResult();

103 }

104

158 */

159

160 // The new result must not have an associated local variable.

161 RegisterSpec newRegSpec = RegisterSpec.make(ssaMeth.makeNewSsaReg(),

162 reg.getTypeBearer());

LocalsArray.java (https://gitlab.com/brian0218/rk3188_rk3066_r-box_android4.4.2_sdk) Java · 181 lines

25

26 /**

27 * Representation of an array of local variables, with Java semantics.

28 *

29 * <p><b>Note:</b> For the most part, the documentation for this class

149

150 /**

151 * Merges this instance with {@code other}. If the merged result is

152 * the same as this instance, then this is returned (not a copy).

153 *

154 * @param other {@code non-null;} another LocalsArray

155 * @return {@code non-null;} the merge result, a new instance or this

156 */

157 public abstract LocalsArray merge(LocalsArray other);

MorphTo.php (https://gitlab.com/judielsm/Handora) PHP · 267 lines

33 * Indicates if soft-deleted model instances should be fetched.

34 *

35 * @var bool

36 */

37 protected $withTrashed = false;

147 {

148 foreach (array_keys($this->dictionary) as $type) {

149 $this->matchToMorphParents($type, $this->getResultsByType($type));

150 }

151

154

155 /**

156 * Match the results for a given type to their parents.

157 *

158 * @param string $type

162 protected function matchToMorphParents($type, Collection $results)

163 {

164 foreach ($results as $result) {

165 if (isset($this->dictionary[$type][$result->getKey()])) {

message_extractor.js (https://gitlab.com/btluis/Angular2_Ejemplo) JavaScript · 166 lines

9 * All messages extracted from a template.

10 */

11 var ExtractionResult = (function () {

12 function ExtractionResult(messages, errors) {

16 return ExtractionResult;

17 }());

18 exports.ExtractionResult = ExtractionResult;

19 /**

20 * Removes duplicate messages.

21 */

22 function removeDuplicates(messages) {

23 var uniq = {};

24 messages.forEach(function (m) {

25 if (!collection_1.StringMapWrapper.contains(uniq, message_1.id(m))) {

89 * 4. If a part has the i18n attribute, stringify the nodes to create a Message.

90 */

91 var MessageExtractor = (function () {

92 function MessageExtractor(_htmlParser, _parser, _implicitTags, _implicitAttrs) {

93 this._htmlParser = _htmlParser;

index.js (https://gitlab.com/alidz1982/cdnjs) JavaScript · 313 lines

1 !function(e){if("object"==typeof exports&&"undefined"!=typeof module)module.exports=e();else if("function"==typeof define&&define.amd)define([],e);else{var f;"undefined"!=typeof window?f=window:"undefined"!=typeof global?f=global:"undefined"!=typeof self&&(f=self),f.co=e()}}(function(){var define,module,exports;return (function e(t,n,r){function s(o,u){if(!n[o]){if(!t[o]){var a=typeof require=="function"&&require;if(!u&&a)return a(o,!0);if(i)return i(o,!0);var f=new Error("Cannot find module '"+o+"'");throw f.code="MODULE_NOT_FOUND",f}var l=n[o]={exports:{}};t[o][0].call(l.exports,function(e){var n=t[o][1][e];return s(n?n:e)},l,l.exports,e,t,n,r)}return n[o].exports}var i=typeof require=="function"&&require;for(var o=0;o<r.length;o++)s(r[o]);return s})({1:[function(require,module,exports){

2 /**

3 * toString() reference.

57

58 function next(err, res) {

59 var ret;

60

61 // multiple args

144 var pending = fns.length;

145 var results = new Array(pending);

146 var finished;

170 }

171

172 results[i] = res;

173 --pending || done(null, results);

196 var pending = keys.length;

197 var results = {};

198 var finished;

AlfMenuBarSelectItemsTest.js (https://github.com/deas/alfresco.git) JavaScript · 267 lines

34 'alfresco/menus/AlfMenuBarSelectItems': function () {

35

36 var browser = this.remote;

37 var testName = "Menu Bar Select Items Test";

49 // Check that nothing is selected on page load...

50 .execute('return dijit.registry.byId("MENU_BAR_SELECT_ITEMS")._itemsSelected.toString()')

51 .then(function(result) {

52 assert(result == "0", "Test #2 - There should be nothing selected on page load");

63 .end()

64 .execute('return dijit.registry.byId("MENU_BAR_SELECT_ITEMS")._itemsSelected.toString()')

65 .then(function(result) {

66 assert(result == "2", "Test #3 - _itemsSelected should be 2 after clicking on ALL");

92

93 .execute('return dijit.registry.byId("MENU_BAR_SELECT_ITEMS")._itemsSelected.toString()')

94 .then(function(result) {

95 assert(result == "0", "Test #4 - _itemsSelected should be 0 after clicking on checkbox image");

StockItemTest.php (https://gitlab.com/yousafsyed/easternglamor) PHP · 257 lines

11 {

12 /**

13 * @var \Magento\CatalogInventory\Model\Quote\Item\QuantityValidator\Initializer\StockItem

14 */

15 protected $model;

16

17 /**

18 * @var QuoteItemQtyList| \PHPUnit_Framework_MockObject_MockObject

19 */

20 protected $quoteItemQtyList;

21

22 /**

23 * @var \Magento\Catalog\Model\ProductTypes\ConfigInterface| \PHPUnit_Framework_MockObject_MockObject

24 */

25 protected $typeConfig;

ResponseReceiver.cs (https://github.com/michaelaird/Agatha.git) C# · 172 lines

26 this.responseReceivedCallback = responseReceivedCallback;

27 this.exceptionOccurredCallback = exceptionOccurredCallback;

28 this.keyToResultPositions = keyToResultPositions;

29 this.cacheManager = cacheManager;

30 }

62 if (disposable == null || !disposable.IsDisposed)

63 {

64 var receivedResponses = args.Result;

65 AddCacheableResponsesToCache(receivedResponses, requestsToSendAsArray);

66 PutReceivedResponsesInTempResponseArray(tempResponseArray, receivedResponses);

118 else

119 {

120 responseReceivedCallback(new ReceivedResponses(args.Result, keyToResultPositions));

121 }

122 }

OS_NS_stropts.cpp (https://github.com/Titan-Project/TrilliumEMU.git) C++ · 193 lines

88

89 // Query for the buffer size.

90 int result = ::WSAIoctl ((ACE_SOCKET) socket,

91 io_control_code,

92 0,

99

100

101 if (result == SOCKET_ERROR)

102 {

103 unsigned long dwErr = ::WSAGetLastError ();

123 QOS *qos = reinterpret_cast<QOS*> (qos_buf);

124

125 result = ::WSAIoctl ((ACE_SOCKET) socket,

126 io_control_code,

127 0,

controller.rb (https://github.com/aryansliet/sorcery.git) Ruby · 197 lines

100 # Tries all available sources (methods) until one doesn't return false.

101 def login_from_other_sources

102 result = nil

103 Config.login_sources.find do |source|

104 result = send(source)

105 end

106 result || false

107 end

108

175 def update!

176 @defaults.each do |k,v|

177 instance_variable_set(k,v) if !instance_variable_defined?(k)

178 end

179 end

spm_mar_spectra.m (https://bitbucket.org/matthewbrett/spm-versions.git) Objective C · 212 lines

14 % .C [Nf x d x d] Coherence matrix

15 % .dtf [Nf x d x d] Kaminski's Directed Transfer Function matrix

16 % .pve [Nf x d x d] Geweke's proportion of variance explained

17 % .gew [Nf x d x d] Geweke's frequency domain Granger causality

18 % .pdc [Nf x d x d] Baccala's Partial Directed Coherence

32 %

33 % In addition to the definition of PDC in the above paper, in this

34 % implementation PDC is also scaled by the observation noise variance

35 % (Baccala, personal communication).

36 %

128

129

130 % plot results if requested

131 %==========================================================================

132 if show

Date.php (https://bitbucket.org/mbaily/tremain.git) PHP · 241 lines

40

41 /**

42 * Find all date variables in the template. The return value

43 * will be passed to process for the main parsing loop.

44 *

59 $week_date = array();

60

61 $date_vars = array('entry_date', 'gmt_date', 'gmt_entry_date', 'edit_date', 'gmt_edit_date', 'expiration_date', 'recent_comment_date', 'week_date');

62

63 ee()->load->helper('date');

64

65 foreach ($date_vars as $val)

66 {

67 if ( ! $pre->has_tag($val))

UpgradeDocumentLibrary.java (https://github.com/viktorkovacs/liferay-portal-trunk.git) Java · 259 lines

24 import java.sql.Connection;

25 import java.sql.PreparedStatement;

26 import java.sql.ResultSet;

27

28 /**

46 Connection con = null;

47 PreparedStatement ps = null;

48 ResultSet rs = null;

49

50 try {

75 Connection con = null;

76 PreparedStatement ps = null;

77 ResultSet rs = null;

78

79 long groupId = 0;

callbacks_test.rb (https://github.com/awscloudtest/rails.git) Ruby · 238 lines

23 test "basic callbacks work" do

24 controller = Callback1.new

25 result = controller.process(:index)

26 assert_equal "Hello world", controller.response_body

27 end

58

59 test "before_filter works" do

60 result = @controller.process(:index)

61 assert_equal "Hello world", @controller.response_body

62 end

64 test "after_filter works" do

65 @controller.process(:index)

66 assert_equal "Goodbye", @controller.instance_variable_get("@second")

67 end

68

GDE3.cpp (https://github.com/wkoder/mocde.git) C++ · 216 lines

43 * Runs the GDE3 algorithm.

44 * @return a <code>SolutionSet</code> that is a set of non dominated solutions

45 * as a result of the algorithm execution

46 */

47 SolutionSet * GDE3::execute() {

73 // cout << "GDE3: maxIterations = " << maxIterations << endl;

74

75 //Initialize the variables

76 population = new SolutionSet(populationSize);

77 evaluations = 0;

128

129 // Dominance test

130 int result ;

131 result = dominance->compare(population->get(i), child) ;

132 if (result == -1) { // Solution i dominates child

133 offspringPopulation->add(new Solution(population->get(i)));

134 delete child;

Rar.php (https://github.com/frhumanes/PLM.git) PHP · 252 lines

44 * )

45 *

46 * @var array

47 */

48 protected $_options = array(

185 unset($options['callback']);

186

187 $result = call_user_func($callback, $options, $content);

188 if ($result !== true) {

AirEncryptedLocalStorageProvider.js (https://github.com/johnjbarton/JavaScriptLibraries.git) JavaScript · 217 lines

81

82 getNamespaces: function(){

83 var results = [ this.DEFAULT_NAMESPACE ];

84 var namespaces = (this._getItem("namespaces")||'|').split('|');

97 }

98

99 var results = [];

100 var keys = (this._getItem(namespace + "_keys")||'|').split('|');

101 for (var i=0;i<keys.length;i++){

102 if (keys[i].length){

103 results.push(keys[i]);

183 }

184

185 var results = [];

186 for(var i=0;i<keys.length;i++){

Abstract.php (https://github.com/netweaver/Rediska.git) PHP · 265 lines

16 * Key name

17 *

18 * @var string

19 */

20 protected $_name;

23 * Exception class name for options

24 *

25 * @var string

26 */

27 protected $_optionsException = 'Rediska_Key_Exception';

35 * rediska - Rediska instance name, Rediska object or Rediska options for new instance

36 *

37 * @var array

38 */

39 protected $_options = array(

ParseException.java (https://github.com/lcamilo15/cfeclipse.git) Java · 191 lines

22 * to force the "toString" method of parent class "Throwable" to

23 * print the error message in the form:

24 * ParseException: <result of getMessage>

25 */

26 public ParseException(Token currentTokenVal,

57

58 /**

59 * This variable determines which constructor was used to create

60 * this object and thereby affects the semantics of the

61 * "getMessage" method (see below).

glquery.math.module.js (https://github.com/circuithub/morpheus.git) JavaScript · 478 lines

4 * Originally created by Rehno Lindeque of http://www.mischievousmeerkat.com

5 */

6 var glQueryMath = new (function() {

7 "use strict";

8

9 var glQueryMath = this != null? this : window;

10 (function(){

11 var gl = glQueryMath;

12

13 // Define a local copy of glQuery

14 var MathMemoryPool = {

15 matrix4: [

16 [0.0,0.0,0.0,0.0, 0.0,0.0,0.0,0.0, 0.0,0.0,0.0,0.0, 0.0,0.0,0.0,0.0],

stringobject.h (https://github.com/tmacreturns/XBMC_wireless_setup.git) C Header · 183 lines

20 string value. The latter function returns a null pointer

21 if the object is not of the proper type.

22 There is a variant that takes an explicit size as well as a

23 variant that assumes a zero-terminated string. Note that none of the

34

35 typedef struct {

36 PyObject_VAR_HEAD

37 long ob_shash;

38 int ob_sstate;

39 char ob_sval[1];

40

41 /* Invariants:

42 * ob_sval contains space for 'ob_size+1' elements.

43 * ob_sval[ob_size] == 0.

117 );

118

119 /* Encodes a string object and returns the result as Python

120 object. */

121

Progress.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 30 lines ✨ Summary

This Java interface defines a contract for reporting installation progress. It provides methods to set the maximum value, advance the progress, indicate completion, and report errors. The interface is designed to be implemented by classes that need to display installation progress, such as ConsoleProgress and SwingProcess. It allows for a standardized way of tracking and displaying installation status.

8 * THIS SOFTWARE IS PROVIDED AS-IS WITHOUT WARRANTY OF ANY KIND, NOT EVEN THE

9 * IMPLIED WARRANTY OF MERCHANTABILITY. THE AUTHOR OF THIS SOFTWARE, ASSUMES

10 * _NO_ RESPONSIBILITY FOR ANY CONSEQUENCE RESULTING FROM THE USE, MODIFICATION,

11 * OR REDISTRIBUTION OF THIS SOFTWARE.

12 */

index.html (https://github.com/tigerpink/cufon.git) HTML · 462 lines

26 }

27

28 .test .result {

29 float: right;

30 text-align: left;

116

117 Cufon.DOM.ready(function() {

118 var divs = document.getElementsByTagName('div'), div, i = 0;

119 while (div = divs[i++]) {

120 if (/result/.test(div.className)) {

144 </div>

145

146 <div class="result">

147

148 <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nullam purus risus, tristique et faucibus sed, aliquet sed dui. Mauris ac enim augue, at dignissim leo. Donec volutpat facilisis dignissim. Phasellus.</p>

createMandelSet.js (https://github.com/wisec/DOMinator.git) JavaScript · 242 lines

193 }

194 }

195 var result;

196 if (doImageData) {

197 if (colorMap == fuzzyColors) {

198 result = mandelbrotImageDataFuzzyResult;

199 } else {

200 result = mandelbrotImageDataModdedResult;

201 }

202 } else {

203 result = mandelbrotNoImageDataResult;

204 }

205 return points.toSource() == result;

mafMatrixTest.cpp (https://github.com/chrisidefix/MAF.git) C++ · 185 lines

121 second.setElement(3, 0, 0.5); second.setElement(3, 1, -1.0);second.setElement(3, 2, 0.5); second.setElement(3, 3, 0.5);

122

123 mafMatrix result;

124 result = first * second;

125 QVERIFY(result.isEqual(identity));

126

127 }

166 mafMatrix resultRowMatrix(1,4);

167 resultRowMatrix.setElement(0, 0, 2.0); resultRowMatrix.setElement(0, 1, 2.0); resultRowMatrix.setElement(0, 2, 0.0); resultRowMatrix.setElement(0, 3, 2.0);

168

169 mafMatrix mRow = matrtix.extractRow(0);

170 bool ok = mRow.isEqual(resultRowMatrix);

171 QVERIFY(ok);

172

RClient.as (https://github.com/metrobg/GLC-Flex.git) ActionScript · 204 lines

10 {

11

12 public var account_type:String;

13 public var active:String;

14 public var activeVerbage:String = '';

15 public var address2:String;

16 public var address:String;

17 public var agentID:Number;

18 public var agentname:String;

19 public var alt_contact:String;

20 public var attempts:String;

21 public var balance:Number;

KeyAgreementException.java (https://github.com/GunioRobot/MI424WR_GEN2_Rev_E-F.git) Java · 178 lines

34 // you permission to link this library with independent modules to

35 // produce an executable, regardless of the license terms of these

36 // independent modules, and to copy and distribute the resulting

37 // executable under terms of your choice, provided that you also meet,

38 // for each linked independent module, the terms and conditions of the

57 public class KeyAgreementException extends KeyManagementException implements Serializable {

58

59 // Constants and variables

60 // -------------------------------------------------------------------------

61

m_track.php (https://bitbucket.org/adifaisalr/popmaya.git) PHP · 282 lines

20 $this->db->limit($limit, $offset);

21 $query = $this->db->get();

22 return $query->result();

23 }*/

24

32 $this->db->limit($limit, $offset);

33 $query = $this->db->get();

34 return $query->result();

35 }

36

102 $this->db->order_by('RAND()','asc');

103 $this->db->limit(1);

104 return $query->result();

105 }

106

ISet.cs (https://github.com/colewerner/nhibernate-core.git) C# · 148 lines

8 /// <c>Set</c> abstraction.

9 /// The order of elements in a set is dependant on (a)the data-structure implementation, and

10 /// (b)the implementation of the various <c>Set</c> methods, and thus is not guaranteed.</p>

11 ///

12 /// <p>None of the <c>Set</c> implementations in this library are guranteed to be thread-safe

22 /// <item>

23 /// <term>Union (OR)</term>

24 /// <term>Element included in result if it exists in either <c>A</c> OR <c>B</c>.</term>

25 /// <term><c>Union()</c></term>

26 /// </item>

27 /// <item>

28 /// <term>Intersection (AND)</term>

29 /// <term>Element included in result if it exists in both <c>A</c> AND <c>B</c>.</term>

30 /// <term><c>InterSect()</c></term>

31 /// </item>

chunk.js (https://github.com/tomislavmitic2012/Node-JS-Playground.git) JavaScript · 209 lines

1 var Binary = require('bson').Binary,

2 ObjectID = require('bson').ObjectID;

3

17 * @see Chunk#buildMongoObject

18 */

19 var Chunk = exports.Chunk = function(file, mongoObject) {

20 if(!(this instanceof Chunk)) return new Chunk(file, mongoObject);

21

22 this.file = file;

23 var self = this;

24 var mongoObjectFinal = mongoObject == null ? {} : mongoObject;

30 if(mongoObjectFinal.data == null) {

31 } else if(typeof mongoObjectFinal.data == "string") {

32 var buffer = new Buffer(mongoObjectFinal.data.length);

33 buffer.write(mongoObjectFinal.data, 'binary', 0);

34 this.data = new Binary(buffer);

class.wpcom-json-api-list-media-v1-1-endpoint.php (https://gitlab.com/juanito.abelo/nlmobile) PHP · 237 lines

3 class WPCOM_JSON_API_List_Media_v1_1_Endpoint extends WPCOM_JSON_API_Endpoint {

4

5 var $date_range = array();

6 var $page_handle = array();

176 }

177

178 // Add a clause that limits the results to items beyond the passed item, or equivalent to the passed item

179 // but with an ID beyond the passed item. When we're ordering by the ID already, we only ask for items

180 // beyond the passed item.

method_core.js (https://github.com/forresst/jquery-mobile-fr_FR.git) JavaScript · 197 lines

3

4 (function( $ ) {

5 var url = $.mobile.path.parseLocation(),

6 home = url.pathname + url.search;

7

37 if( $.support.pushState ) {

38 test( "navigation should squish the hash", function() {

39 var destination = home + "#foo";

40

41 ok( location.hash.indexOf( "foo" ) == -1, "the hash is clean" );

44 $.mobile.navigate( destination );

45

46 equal( $.mobile.path.parseLocation().pathname, url.pathname, "the resulting url has the same pathname as the original test url" );

47 equal( location.hash, "#foo", "the hash has been altered" );

48 });

ccg_sqlserver_utils.py (https://github.com/bretambrose/CCGOnlinePublic.git) Python · 190 lines

11

12 def LoadDBSettings():

13 assign_re = re.compile( "(?P<var>\w+)=(?P<value>\S*)" )

14 db_kv_pairs = {}

15

17 db_settings_file = open( "../DBSettings.txt", 'r' )

18

19 # read the file, pulling out key value pairs in the form of "var=value"

20 line = db_settings_file.readline()

21 while line != "":

22 result = assign_re.search( line )

23 if result != None:

24 variable_name = result.group( "var" )

25 value = result.group( "value" )

location_manager.js (https://github.com/GunioRobot/mineflayer.git) JavaScript · 169 lines

11 var coords = literal_matches.mapped(function(s) { return parseInt(s); });

12 var point = new mf.Point(coords[0], coords[1], coords[2]);

13 return [{"name": "[literal]", "point": point}];

14 }

42 };

43 location_manager.findUnambiguousLocation = function(location_name, responder_func) {

44 var search_results = location_manager.searchLocations(location_name);

45 if (search_results.length === 0) {

69 var name = args[0];

70 var entity = player_tracker.entityForPlayer(speaker);

71 if (entity === undefined) {

72 responder_fun("sorry, can't see user: " + speaker);

73 return;

74 }

75 var point;

76 var cursor = entity.position.offset(0, entity.height, 0);

RavenDB_1761.cs (https://github.com/fitzchak/ravendb.git) C# · 181 lines

24 public void DateFacetTest()

25 {

26 using (var store = NewDocumentStore(requestedStorage: "esent"))

27 {

28 new SampleData_Index().Execute(store);

36 using (var session = store.OpenSession())

37 {

38 var result = session.Query<SampleData, SampleData_Index>()

39 .ToFacets("dateFacets");

40

41 foreach (KeyValuePair<string, FacetResult> facet in result.Results)

42 {

43 if (facet.Key == "CDate")

chebyshev.py (https://gitlab.com/pooja043/Globus_Docker_3) Python · 226 lines

3 """

4 This module describes routines for computing Chebyshev

5 approximations to univariate functions. A Chebyshev approximation is a

6 truncation of the series \M{f(x) = S{sum} c_n T_n(x)}, where the Chebyshev

7 polynomials \M{T_n(x) = cos(n \arccos x)} provide an orthogonal basis of

97 """

98 This function computes the Chebyshev series at a given point X,

99 estimating both the series RESULT and its absolute error ABSERR.

100 The error estimate is made from the first neglected term in the

101 series.

121 """

122 This function evaluates a Chebyshev series CS at a given point X,

123 estimating both the series RESULT and its absolute error ABSERR,

124 to (at most) the given order ORDER. The error estimate is made

125 from the first neglected term in the series.

import_service_spec.rb (https://gitlab.com/alexsanford/gitlab-ce) Ruby · 183 lines

16 expect(project).to receive(:create_repository).and_return(true)

17

18 result = subject.execute

19

20 expect(result[:status]).to eq :success

24 expect(project).to receive(:create_repository).and_return(false)

25

26 result = subject.execute

27

28 expect(result[:status]).to eq :error

29 expect(result[:message]).to eq "Error importing repository #{project.import_url} into #{project.path_with_namespace} - The repository could not be created."

30 end

31 end

42 expect_any_instance_of(Gitlab::GithubImport::Importer).to receive(:execute).and_return(true)

43

44 result = subject.execute

45

46 expect(result[:status]).to eq :success

AdapterTest.php (https://gitlab.com/yousafsyed/easternglamor) PHP · 187 lines

14 {

15 /**

16 * @var ResponseFactory|\PHPUnit_Framework_MockObject_MockObject

17 */

18 protected $responseFactory;

19

20 /**

21 * @var \Magento\Framework\DB\Adapter\AdapterInterface|\PHPUnit_Framework_MockObject_MockObject

22 */

23 private $connectionAdapter;

24

25 /**

26 * @var \Magento\Framework\Search\Adapter\Mysql\Mapper|\PHPUnit_Framework_MockObject_MockObject

27 */

28 private $mapper;

BasicBlock.java (https://github.com/rkh/jruby.git) Java · 191 lines

128 // SSS FIXME: Verify correctness; also deal with YieldInstr.wrapIntoArray flag

129 public void processClosureArgAndReturnInstrs(InlinerInfo ii, YieldInstr yi) {

130 Variable yieldResult = ii.getRenamedVariable(yi.result);

131 Operand[] yieldArgs = yi.getNonBlockOperands();

132

142 // a block Ex: ... r.foo(args) { ... blah .. }. i.e. there are scenarios where %self

143 // within the block is not identical to 'r'. Handle this!

144 if (!rsi.result.equals(ii.getCallReceiver())) it.set(new CopyInstr(rsi.result, ii.getCallReceiver()));

145 else it.set(NopInstr.NOP);

146 }

147 else if (i instanceof ReceiveClosureInstr) {

148 ReceiveClosureInstr rci = (ReceiveClosureInstr)i;

149 if (!rci.result.equals(ii.getCallClosure())) it.set(new CopyInstr(rci.result, ii.getCallClosure()));

150 else it.set(NopInstr.NOP);

151 }

DbLoginEventsManager.cs (https://gitlab.com/rekby-archive/onlyoffice-CommunityServer) C# · 188 lines

67 .Select("id")

68 .Where(where);

69 var resultList = db.ExecuteList(query).Select(row => (int)row[0]).ToList();

70

71 if (resultList != null)

72 {

73 cache.Insert(commonKey, resultList, expirationTimeout);

74 }

75

87 .Where(where)

88 .OrderBy("id", false);

89 var loginInfo = db.ExecuteList(query).Select(row => new BaseEvent

90 {

91 Id = (int)row[0],

tileview.php (https://gitlab.com/alexprowars/bitrix) PHP · 314 lines

27 const MAX_COUNT = 4;

28

29 /** @var bool $isInclude Is include. */

30 protected $isInclude = true;

31

32 /** @var Message\Adapter $message Message. */

33 protected $message;

34

108 if ($tile['data']['last'])

109 {

110 /** @var \Bitrix\Main\Type\DateTime $last */

111 $last = $tile['data']['last'];

112 $tile['data']['last'] = $last->getTimestamp();

manager.php (https://gitlab.com/alexprowars/bitrix) PHP · 315 lines

163 if (!is_array($result))

164 {

165 $result = array();

166 }

167

245 $event->send();

246

247 foreach ($event->getResults() as $eventResult)

248 {

249 if ($eventResult->getType() == EventResult::ERROR)

254 $eventResultParameters = $eventResult->getParameters();

255

256 if($eventResultParameters && array_key_exists('CONNECTOR', $eventResultParameters))

257 {

258 $connectorClassNameList = $eventResultParameters['CONNECTOR'];

template.php (https://gitlab.com/alexprowars/bitrix) PHP · 168 lines

2 /** @var array $arParams */

3 /** @var array $arResult */

4 /** @global CMain $APPLICATION */

5 /** @global CUser $USER */

6 /** @global CDatabase $DB */

7 /** @var CBitrixComponentTemplate $this */

8 /** @var string $templateName */

9 /** @var string $templateFile */

10 /** @var string $templateFolder */

17 ?>

18 <div class="mb-3 catalog-filter<?=$themeClass?>">

19 <form name="<?echo $arResult["FILTER_NAME"]."_form"?>" action="<?echo $arResult["FORM_ACTION"]?>" method="get">

20 <div class="container-fluid">

21 <div class="mb-3 row">

future.rb (https://gitlab.com/CORP-RESELLER/aws-flow-ruby) Ruby · 220 lines

36

37 def initialize

38 @conditional = FiberConditionVariable.new

39 @set = false

40 end

46 raise AlreadySetException if @set

47 @set = true

48 @result = result

49 @listeners.each { |b| b.call(self) } if @listeners

50 @conditional.broadcast if @conditional

110 # Have the current fiber wait on this condition variable, and wake up

111 # when the FiberConditionVariable is signaled/broadcasted.

112 #

113 # @api private

159

160 def initialize

161 @conditional = ConditionVariable.new

162 @mutex = Mutex.new

163 @set = false

UnfairSupplierResource.java (https://gitlab.com/bourd0n/zakupki) Java · 148 lines

58 return ResponseEntity.badRequest().headers(HeaderUtil.createFailureAlert(ENTITY_NAME, "idexists", "A new unfairSupplier cannot already have an ID")).body(null);

59 }

60 UnfairSupplier result = unfairSupplierService.save(unfairSupplier);

61 return ResponseEntity.created(new URI("/api/unfair-suppliers/" + result.getId()))

62 .headers(HeaderUtil.createEntityCreationAlert(ENTITY_NAME, result.getId().toString()))

63 .body(result);

80 return createUnfairSupplier(unfairSupplier);

81 }

82 UnfairSupplier result = unfairSupplierService.save(unfairSupplier);

83 return ResponseEntity.ok()

84 .headers(HeaderUtil.createEntityUpdateAlert(ENTITY_NAME, unfairSupplier.getId().toString()))

85 .body(result);

86 }

87

RegistrationKoResource.java (https://gitlab.com/bourd0n/zakupki) Java · 148 lines

58 return ResponseEntity.badRequest().headers(HeaderUtil.createFailureAlert(ENTITY_NAME, "idexists", "A new registrationKo cannot already have an ID")).body(null);

59 }

60 RegistrationKo result = registrationKoService.save(registrationKo);

61 return ResponseEntity.created(new URI("/api/registration-kos/" + result.getId()))

62 .headers(HeaderUtil.createEntityCreationAlert(ENTITY_NAME, result.getId().toString()))

63 .body(result);

80 return createRegistrationKo(registrationKo);

81 }

82 RegistrationKo result = registrationKoService.save(registrationKo);

83 return ResponseEntity.ok()

84 .headers(HeaderUtil.createEntityUpdateAlert(ENTITY_NAME, registrationKo.getId().toString()))

85 .body(result);

86 }

87

Entity.php (https://gitlab.com/reasonat/test8) PHP · 198 lines

19

20 /**

21 * Stores the entity type of the result entities.

22 *

23 * @var string

28 * The entity manager.

29 *

30 * @var \Drupal\Core\Entity\EntityManagerInterface

31 */

32 protected $entityManager;

std_logic_signed.vhd (https://github.com/nickg/nvc.git) VHDL · 343 lines

146 -- pragma label_applies_to minus

147 constant length: INTEGER := maximum(L'length, R'length);

148 variable result : STD_LOGIC_VECTOR (length-1 downto 0);

149 begin

150 result := SIGNED(L) - SIGNED(R); -- pragma label minus

210 -- pragma label_applies_to mult

211 constant length: INTEGER := maximum(L'length, R'length);

212 variable result : STD_LOGIC_VECTOR ((L'length+R'length-1) downto 0);

213 begin

214 result := SIGNED(L) * SIGNED(R); -- pragma label mult

334 -- using a conversion function in std_logic_arith

335 function CONV_INTEGER(ARG: STD_LOGIC_VECTOR) return INTEGER is

336 variable result : SIGNED(ARG'range);

337 begin

338 result := SIGNED(ARG);

o2.dom.dimension.js (https://github.com/v0lkan/o2.js.git) JavaScript · 477 lines

68 }

69

70 var result = (document.documentElement &&

71 document.compatMode === kModernCss

72 ) ? document.documentElement : document.body;

89 *

90 * <pre>

91 * var dimensions = o2.Dom.getDimension('container');

92 * </pre>

93 *

127 *

128 * <pre>

129 * var viewportInfo = o2.Dom.getDocumentDimension();

130 * </pre>

131 *

Node.cs (https://bitbucket.org/sebastian_ebert/attacktrees.git) C# · 387 lines

22 private Guid _id;

23 private string _name;

24 private bool _isResult;

25 private bool _isExpanded;

26 private bool _isSelected;

63 this.Attributes = new Dictionary<string, NodeAttribute>();

64 this.IsExpanded = true;

65 this.IsResult = false;

66 this.IsSelected = false;

67 this.ShowsAttributes = true;

153 /// <summary>

154 /// Gets or sets if the node is part of the last

155 /// function runs result.

156 /// </summary>

157 public bool IsResult

CompilerInvocation.h (https://github.com/lygstate/safecode-mirror.git) C Header · 194 lines

61 HeaderSearchOptions HeaderSearchOpts;

62

63 /// Options controlling the language variant.

64 LangOptions LangOpts;

65

82 /// options.

83 ///

84 /// \param Res [out] - The resulting invocation.

85 /// \param ArgBegin - The first element in the argument vector.

86 /// \param ArgEnd - The last element in the argument vector.

File.php (https://bitbucket.org/acidel/buykoala.git) PHP · 198 lines

40 class Zend_Pdf_FileParserDataSource_File extends Zend_Pdf_FileParserDataSource

41 {

42 /**** Instance Variables ****/

43

44

45 /**

46 * Fully-qualified path to the file.

47 * @var string

48 */

49 protected $_filePath = '';

51 /**

52 * File resource handle .

53 * @var resource

54 */

55 protected $_fileResource = null;

mul_1.asm (https://bitbucket.org/pizzafactory/blackfin-toolchain.git) Assembly · 276 lines

1 dnl SPARC v9 32-bit mpn_mul_1 -- Multiply a limb vector with a limb and store

2 dnl the result in a second limb vector.

3

4 dnl Copyright 1998, 2000, 2001, 2003 Free Software Foundation, Inc.

22

23 C Algorithm: We use two floating-point multiplies per limb product, with the

24 C invariant v operand split into two 16-bit pieces, and the u operand split

25 C into 32-bit pieces. We convert the two 48-bit products and transfer them to

26 C the integer unit.

214 fmuld %f2, %f6, %f4

215 C -- 5

216 xor %o5, 16, %o5 C alternate scratch variables

217 stw %g4, [%o0-4]

218 bne,pt %icc, .Loop

DefaultValidatorTest.php (https://gitlab.com/crazybutterfly815/magento2) PHP · 163 lines

10 {

11 /**

12 * @var \Magento\Catalog\Model\Product\Option\Validator\DefaultValidator

13 */

14 protected $validator;

15

16 /**

17 * @var \PHPUnit_Framework_MockObject_MockObject

18 */

19 protected $valueMock;

74 * @param $product

75 * @param $messages

76 * @param $result

77 * @dataProvider isValidTitleDataProvider

78 */

cipher.h (https://github.com/batt/StratoSpera.git) C Header · 219 lines

22 * templates or use macros or inline functions from this file, or you compile

23 * this file and link it with other files to produce an executable, this

24 * file does not by itself cause the resulting executable to be covered by

25 * the GNU General Public License. This exception does not however

26 * invalidate any other reasons why the executable file might be covered by

57 * Return the key length (in bytes).

58 *

59 * In case of ciphers that allow a variabile key size with a fixed state

60 * (eg: Blowfish), this returns the preferred key length.

61 */

87

88 /**

89 * Set the current key (of variable size) used by the cipher.

90 *

91 * This function is useful for ciphers that allow a variable size for the key

pod.el (https://github.com/gjuggler/bioperl-live.git) Emacs Lisp · 224 lines

4 ;;

5 ;; Emacs functions for simple Perl pod parsing

6 ;; parse result format based on pod2text

7 ;;

8 ;; required in bioperl-mode.el

33 ;; Boston, MA 02110-1301 USA

34

35 (defvar pod-keywords

36 '( "pod" "head1" "head2" "head3" "head4" "over" "item" "back" "begin" "end" "for" "encoding" "cut" )

37 "Perl pod keywords (sans '=') ")

38

39 (defvar pod-format-codes

40 '( "I" "B" "C" "L" "E" "F" "S" "X" "Z" )

41 "Perl pod format codes (sans <>)" )

tests_setvalue.js (https://gitlab.com/cavadu/mercatitulo) JavaScript · 182 lines

13 qunit.module("Set value with fn.val");

14 test("inputmask(\"decimal\") ~ value=\"123.45\"", function() {

15 var $fixture = $("#qunit-fixture");

16 $fixture.append('<input type="text" id="testmask" />');

17 var testmask = document.getElementById("testmask");

18 Inputmask("decimal").mask(testmask);

19 $("#testmask").val("123.45");

20 equal(testmask.value, "123.45", "Result " + testmask.value);

21

22 $("#testmask").remove();

24

25 test("inputmask(\"9\") ~ value=\"1\"", function() {

26 var $fixture = $("#qunit-fixture");

27 $fixture.append('<input type="text" id="testmask" />');

28 var testmask = document.getElementById("testmask");

TableGisVisualizationController.php (https://gitlab.com/trungthao379/phpmyadmin) PHP · 214 lines

28

29 /**

30 * @var array $url_params

31 */

32 protected $url_params;

33

34 /**

35 * @var string $sql_query

36 */

37 protected $sql_query;

38

39 /**

40 * @var array $visualizationSettings

41 */

42 protected $visualizationSettings;

SendSmsTest.php (https://bitbucket.org/Dal-Papa/is-340-publish-base.git) PHP · 213 lines

43 {

44 /**

45 * @var Zend_Service_DeveloperGarden_SendSms_Mock

46 */

47 protected $_service = null;

136 );

137

138 $result = $this->service->send($sms);

139 $this->assertType(

140 'Zend_Service_DeveloperGarden_Response_SendSms_SendSMSResponse',

141 $result

142 );

143

DynamicModels.cs (https://github.com/lefthandedgoat/Oak.git) C# · 241 lines

135 options = (options as object).ToPrototype();

136

137 var results = new List<dynamic>();

138

139 foreach (dynamic model in Models) if (IsMatch(options, model)) results.Add(model);

191 }

192

193 result = new DynamicModels(result as HashSet<dynamic>);

194

195 return true;

208 public DynamicModels Include(params string[] methods)

209 {

210 var result = new object();

211

212 methods.ForEach(s =>

collate_test.go (https://bitbucket.org/shimberger/go-experimental.git) Go · 422 lines

59 }

60

61 var zero = w(0, 0, 0, 0)

62

63 var processTests = []weightsTest{

64 // Shifted

65 { // simple sequence of non-variables

66 opt: opts{alt: collate.AltShifted, top: 100},

67 in: ColElems{w(200), w(300), w(400)},

68 out: ColElems{wpq(200, maxQ), wpq(300, maxQ), wpq(400, maxQ)},

69 },

70 { // first is a variable

71 opt: opts{alt: collate.AltShifted, top: 250},

72 in: ColElems{w(200), w(300), w(400)},

abstract.php (https://bitbucket.org/organicdevelopment/nooku-framework.git) PHP · 257 lines

24 * The object doing the mixin

25 *

26 * @var object

27 */

28 protected $_mixer;

31 * Class methods

32 *

33 * @var array

34 */

35 private $__methods = array();

38 * List of mixable methods

39 *

40 * @var array

41 */

42 private $__mixable_methods;

render_node.js (https://github.com/dkim-95112/movie_rails.git) JavaScript · 217 lines

58 * just once. For example:

59 *

60 * var children = renderNode.children;

61 * for (var i = 0; i < children.length; i++) {

62 * var child = children[i];

63 * }

64 *

152 * Searches for render nodes that match the given name in the hierarchy under

153 * and including this render node. Since there can be several render nodes

154 * with a given name the results are returned in an array.

155 *

156 * Note that modifications to this array [e.g. push()] will not affect

194 }

195 this.children.sort(compare);

196 var children = this.children;

197

198 this.before();

index.html (https://jedit.svn.sourceforge.net/svnroot/jedit) HTML · 507 lines ✨ Summary

This is an HTML document that describes a plugin for the jEdit text editor. It provides information on how to use the plugin, its features, and settings. The document includes details on the plugin’s functionality, such as displaying line diffs and merge controls, and configuring colors and layout options. It also includes licensing information and credits for contributors.

15 document under the terms of the GNU Free Documentation License,

16 Version 1.1 or any later version published by the Free Software

17 Foundation; with no Invariant Sections, Front-Cover Texts or

18 Back-Cover Texts, each as defined in the license. A copy of the

19 license can be found in the file COPYING.DOC.txt included with

110 </ol>

111

112 <p>Figure 1 shows the result</p>

113

114 <img alt="" src="diff_overview.jpg" format="JPG">

454 <li>

455 <p>Version 1.8. Bug fixes, added "Diff" and "Refresh" buttons to

456 merge controls, major code refactoring to clean up the various

457 painting issues.</p>

458 </li>

schkec.f (https://github.com/jackygrahamez/DrugDiscovery-Home.git) FORTRAN Legacy · 181 lines

19 *

20 * In all cases, the routine runs through a fixed set of numerical

21 * examples, subjects them to various tests, and compares the test

22 * results to a threshold THRESH. In addition, STREXC, STRSNA and STRSEN

integration.coffee (https://github.com/pthrasher/snockets.git) CoffeeScript · 167 lines

91 throw err if err

92 test.deepEqual chain, [

93 {filename: 'sybling/sybling.js', js: 'var thereWillBeJS = 3;'}

94 {filename: 'first/syblingFolder.js', js: '//= require ../sybling/sybling.js'}

95 ]

100 throw err if err

101 test.equal js1, """

102 var thereWillBeJS = 3;

103 //= require ../sybling/sybling.js

104 """

147 snockets.options.staticRootUrl = '/assets/'

148

149 snockets.getConcatenation 'z.coffee', minify: true, (err, result) ->

150 throw err if err

151 { js, srcmap } = result

CurlRequest.php (https://github.com/medieteknik/Medieteknik.nu.git) PHP · 197 lines

57

58 /**

59 * Send the request and store the results.

60 *

61 * @return bool true on success, false on failure.

133 * Configure curl to capture our output.

134 *********************************************************/

135 // return the CURL output into a variable

136 curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);

137

mpi_x86_os2.s (https://github.com/rillian/firefox.git) Assembly · 538 lines

22 #

23 #.ifndef NO_PIC

24 #.macro GET var,reg

25 # movl \var@GOTOFF(%ebx),\reg

26 #.endm

27 #.macro PUT reg,var

28 # movl \reg,\var@GOTOFF(%ebx)

29 #.endm

30 #.else

31 .macro GET var,reg

32 movl \var,\reg

33 .endm

34 .macro PUT reg,var

35 movl \reg,\var

ltablib.c (https://github.com/SAPikachu/aegisub_2.1.9.git) C · 250 lines

30 if (!lua_isnil(L, -1))

31 return 1;

32 lua_pop(L, 1); /* remove nil result */

33 }

34 return 0;

49 if (!lua_isnil(L, -1))

50 return 1;

51 lua_pop(L, 2); /* remove value and result */

52 }

53 }

94 if (n <= 0) return 0; /* table is `empty' */

95 luaL_setn(L, 1, n-1); /* t.n = n-1 */

96 lua_rawgeti(L, 1, pos); /* result = t[pos] */

97 for ( ;pos<n; pos++) {

98 lua_rawgeti(L, 1, pos+1);

session.php (https://github.com/ameximes/akelos.git) PHP · 231 lines

35 *

36 * @access protected

37 * @var object $_driverInstance

38 */

39 public $_driverInstance;

44 *

45 * @access private

46 * @var string $_db

47 */

48 public $_original_sess_value = '';

112 $this->_driverInstance = new AkCookieStore();

113 $this->_driverInstance->init($options);

114 Ak::setStaticVar('SessionHandler', $this->_driverInstance);

115 return true;

116 default:

185 $result = $this->_driverInstance->get($id,'AK_SESSIONS');

186 return is_null($result) ? '' : (string)$result;

187 }

188

auto_nlist.c (https://github.com/rhuitl/uClinux.git) C · 236 lines

93

94 int

95 auto_nlist(const char *string, char *var, int size)

96 {

97 long result;

98 int ret;

99 result = auto_nlist_value(string);

100 if (result != -1) {

101 if (var != NULL) {

102 ret = klookup(result, var, size);

103 if (!ret)

104 snmp_log(LOG_ERR,

105 "auto_nlist failed on %s at location %lx\n",

106 string, result);

107 return ret;

108 } else

migrate_block_info_to_cms_block.php (https://gitlab.com/jslee1/PrestaShop) PHP · 133 lines

43 WHERE name="PS_LANG_DEFAULT"');

44 // 2) parent::install()

45 $result = Db::getInstance()->insert('module',

46 array('name' => 'blockcms', 'active' => 1));

47 $id_module = Db::getInstance()->insert_Id();

73 `id_cms_block` int(10) unsigned NOT NULL,

74 `id_lang` int(10) unsigned NOT NULL,

75 `name` varchar(40) NOT NULL default \'\',

76 PRIMARY KEY (`id_cms_block`, `id_lang`)

77 ) ENGINE='._MYSQL_ENGINE_.' DEFAULT CHARSET=utf8');

arm_std_q15.c (https://gitlab.com/locsonpham/demeter_weatherstation) C · 197 lines

113 /* C = (A[0] * A[0] + A[1] * A[1] + ... + A[blockSize-1] * A[blockSize-1]) */

114 /* Compute Sum of squares of the input samples

115 * and then store the result in a temporary variable, sum. */

116 in1 = *pSrc++;

117 sumOfSquares = __SMLALD(in1, in1, sumOfSquares);

160

161 /* C = (A[0] + A[1] + A[2] + ... + A[blockSize-1]) */

162 /* Compute sum of all input values and then store the result in a temporary variable, sum. */

163 sum += in;

164

177

178 /* Compute square of mean of the input samples

179 * and then store the result in a temporary variable, squareOfMean.*/

180 t = (q15_t) ((1.0 / (blockSize * (blockSize - 1))) * 32768LL);

181 squareOfMean = ((q31_t) mean * mean) >> 15;

arm_shift_q15.c (https://gitlab.com/locsonpham/demeter_weatherstation) C · 243 lines

56 * \par

57 * The function uses saturating arithmetic.

58 * Results outside of the allowable Q15 range [0x8000 0x7FFF] will be saturated.

59 */

60

72 /* Run the below code for Cortex-M4 and Cortex-M3 */

73

74 q15_t in1, in2; /* Temporary variables */

75

76

92 in2 = *pSrc++;

93 /* C = A << shiftBits */

94 /* Shift the inputs and then store the results in the destination buffer. */

95 #ifndef ARM_MATH_BIG_ENDIAN

96

Concurrent.scala (https://github.com/julienrf/playframework.git) Scala · 232 lines

52 val iteratees: Ref[List[(Iteratee[E, _], Redeemable[Iteratee[E, _]])]] = Ref(List())

53

54 var closeFlag = false

55

56 def step(in: Input[E]): Iteratee[E, Unit] = {

128 def apply[A](it: Iteratee[E, A]): Promise[Iteratee[E, A]] = {

129

130 val result = Promise[Iteratee[E, A]]()

131 iteratees.single.transform(_ :+ ((it, result.asInstanceOf[Redeemable[Iteratee[E, _]]])))

132 result

133

134 }

151

152 def apply[A](it: Iteratee[E, A]): Promise[Iteratee[E, A]] = {

153 val result = Promise[Iteratee[E, A]]()

154 var isClosed: Boolean = false

Barcode.php (https://github.com/Riges/KawaiViewModel.git) PHP · 228 lines

51

52 /**

53 * Additional variables available for validation failure messages

54 *

55 * @var array

56 */

57 protected $_messageVariables = array(

58 'length' => '_length'

59 );

62 * Length for the set subtype

63 *

64 * @var integer

65 */

66 protected $_length;

ReentrantWriterPreferenceReadWriteLock.java (https://github.com/machak/intellij-community.git) Java · 234 lines

201 if (thread == myLastThread) return myLastCounter;

202 int index = myThreads.indexOf(thread);

203 int result = index >= 0 ? myCounters.getQuick(index) : 0;

204 myLastThread = thread;

205 myLastCounter = result;

206 return result;

207 }

208

HyperSearchNode.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 33 lines ✨ Summary

This is a Java interface definition for HyperSearchNode. It represents a node in a hyper search result, providing methods to access the associated buffer and navigate to it within an edit pane. The interface defines two methods: getBuffer() returns the buffer associated with this node, and goTo(EditPane editPane) navigates to this node within the given edit pane.

1 /*

2 * HyperSearchResult.java - HyperSearch result

3 * :tabSize=8:indentSize=8:noTabs=false:

4 * :folding=explicit:collapseFolds=1:

delete.hpp (http://hadesmem.googlecode.com/svn/trunk/) C++ Header · 0 lines ✨ Summary

This C++ header defines a function delete_ that takes an object of type P and deletes its contents using the boost::phoenix library’s composition mechanism. The impl::delete_eval struct is used to define the deletion behavior, which simply calls the eval function on the object being deleted.

17 {

18 template <typename Env, typename P>

19 struct result

20 {

21 typedef void type;

JSInt32Array.cpp (https://bitbucket.org/ultra_iter/qt-vtl.git) C++ · 282 lines

185 UNUSED_PARAM(exec);

186 Int32Array* imp = static_cast<Int32Array*>(castedThis->impl());

187 JSValue result = jsNumber(imp->length());

188 return result;

239 if (argsCount <= 1) {

240

241 JSC::JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->subarray(start)));

242 return JSValue::encode(result);

248

249

250 JSC::JSValue result = toJS(exec, castedThis->globalObject(), WTF::getPtr(imp->subarray(start, end)));

251 return JSValue::encode(result);

russellallen.mode1v3.LOCAL.1552.mode1v3 (git://github.com/ticking/self.git) Unknown · 1389 lines

53 <string>1</string>

54 <key>Module</key>

55 <string>PBXBuildResultsModule</string>

56 <key>Name</key>

57 <string>Detailed Build Results Viewer</string>

570 <dict>

571 <key>PBXProjectModuleGUID</key>

572 <string>XCMainBuildResultsModuleGUID</string>

573 <key>PBXProjectModuleLabel</key>

574 <string>Build</string>

575 <key>XCBuildResultsTrigger_Collapse</key>

576 <integer>1021</integer>

577 <key>XCBuildResultsTrigger_Open</key>

go7007.txt (http://omnia2droid.googlecode.com/svn/trunk/) Unknown · 482 lines

142 this section.

143

144 The wide variety of PAL TV systems used in Europe requires that additional

145 information about the local TV standards be passed to the driver in order

146 to properly tune TV channels. The two necessary parameters are (a) the PAL

166 The other parameter that can be specified is the audio subchannel format.

167 There are several stereo audio carrier systems in use, including NICAM and

168 three varieties of A2. To receive audio broadcast on one of these stereo

169 carriers, the "force_mpx_mode" parameter must be specified to the

170 wis-sony-tuner module.

191 To pass the "force_band" or "force_mpx_mode" parameters to the

192 wis-sony-tuner module, the following line must be added to the modprobe

193 configuration file, which varies from one Linux distribution to another.

194

195 options wis-sony-tuner force_band=B force_mpx_mode=2

malloc.c (https://bitbucket.org/ultra_iter/qt-vtl.git) C · 5515 lines

26 ftp it, compile it (-O3), and link it into another program. All of

27 the compile-time options default to reasonable values for use on

28 most platforms. You might later want to step through various

29 compile-time and dynamic tuning options.

30

81 ends of chunks) in code that calls malloc. This malloc

82 guarantees not to modify any memory locations below the base of

83 heap, i.e., static variables, even in the presence of usage

84 errors. The routines additionally detect most improper frees

85 and reallocs. All this holds as long as the static bookkeeping

145 most tunable malloc ever written. However it is among the fastest

146 while also being among the most space-conserving, portable and

147 tunable. Consistent balance across these factors results in a good

148 general-purpose allocator for malloc-intensive programs.

149

graphviz.hpp (http://hadesmem.googlecode.com/svn/trunk/) C++ Header · 0 lines ✨ Summary

This C++ header file provides a way to visualize graphs using Graphviz, a popular graph visualization tool. It allows users to write graph data in various formats and then generates Graphviz code that can be used to render the graph as an image or diagram. The library supports distributed computing, enabling it to handle large graphs across multiple processes.

171 out << "}\n";

172 } else {

173 std::string result_str = local_graph_out.str();

174 const char* data = result_str.c_str();

175

176 int len = result_str.length();

177 send(pg, 0, 0, len);

178 send(pg, 0, 1, data, len);

TranslatedKeyEvent.java (http://softkeyboard.googlecode.com/svn/) Java · 80 lines ✨ Summary

This Java code defines a custom KeyEvent class called TranslatedKeyEvent, which extends the original KeyEvent class. It adds additional functionality to provide more information about key events, such as Unicode character codes and display labels, while also logging debug messages if debugging is enabled. The class overrides various methods from the original KeyEvent class to achieve this.

47 //

48 // @Override

49 // public boolean getKeyData(KeyData results) {

50 // if (AnySoftKeyboard.getDEBUG()) Log.d("AnySoftKeyboard:TranslatedKeyEvent", "getKeyData");

51 // return super.getKeyData(results);

state_switcher.hpp (http://hadesmem.googlecode.com/svn/trunk/) C++ Header · 0 lines ✨ Summary

This C++ header file provides a set of parsers and utilities for working with lexer states in Boost.Spirit, a parser generator library. It defines two main parsers: state_switcher for switching between lexer states during parsing, and state_switcher_context for executing embedded sub-parsers within a specific state. The code also includes utility functions for creating these parsers from terminal expressions.

228 {

229 typedef typename add_const<State>::type const_string;

230 typedef state_switcher<const_string> result_type;

231

232 template <typename Terminal>

233 result_type operator()(Terminal const& term, unused_type) const

234 {

235 return result_type(traits::get_c_string(fusion::at_c<0>(term.args)));

242 {

243 typedef typename add_const<State>::type const_string;

244 typedef state_switcher_context<Subject, const_string> result_type;

245

246 template <typename Terminal>

JSRealtimeAnalyserNode.cpp (https://bitbucket.org/ultra_iter/qt-vtl.git) C++ · 317 lines

169 UNUSED_PARAM(exec);

170 RealtimeAnalyserNode* imp = static_cast<RealtimeAnalyserNode*>(castedThis->impl());

171 JSValue result = jsNumber(imp->fftSize());

172 return result;

179 UNUSED_PARAM(exec);

180 RealtimeAnalyserNode* imp = static_cast<RealtimeAnalyserNode*>(castedThis->impl());

181 JSValue result = jsNumber(imp->frequencyBinCount());

182 return result;

189 UNUSED_PARAM(exec);

190 RealtimeAnalyserNode* imp = static_cast<RealtimeAnalyserNode*>(castedThis->impl());

191 JSValue result = jsNumber(imp->minDecibels());

192 return result;

199 UNUSED_PARAM(exec);

200 RealtimeAnalyserNode* imp = static_cast<RealtimeAnalyserNode*>(castedThis->impl());

201 JSValue result = jsNumber(imp->maxDecibels());

202 return result;

text-edit.xml (https://jedit.svn.sourceforge.net/svnroot/jedit) XML · 1246 lines

77

78 <para>However you can rebind them to anything you want, for example,

79 various combinations of the following, or indeed any other command

80 or macro:</para>

81

215 active; see <xref linkend="status-bar" />.</para>

216

217 <para>Various jEdit commands behave differently with multiple

218 selections:</para>

219

299 <para>When inserting text, the <keycap>TAB</keycap> and

300 <keycap>ENTER</keycap> keys might not behave entirely like you expect

301 because of various indentation features; see <xref linkend="indent" />

302 for details.</para>

303

RenderSVGResourceClipper.cpp (https://bitbucket.org/ultra_iter/qt-vtl.git) C++ · 346 lines

29 #include "GraphicsContext.h"

30 #include "HitTestRequest.h"

31 #include "HitTestResult.h"

32 #include "ImageBuffer.h"

33 #include "IntRect.h"

261 svgStyle->setMaskerResource(String());

262

263 // The setStyle() call results in a styleDidChange() call, which in turn invalidations the resources.

264 // As we're mutating the resource on purpose, block updates until we've resetted the style again.

265 m_invalidationBlocked = true;

314 continue;

315 IntPoint hitPoint;

316 HitTestResult result(hitPoint);

317 if (renderer->nodeAtFloatPoint(HitTestRequest(HitTestRequest::SVGClipContent), result, point, HitTestForeground))

actor_operator_10.hpp (http://hadesmem.googlecode.com/svn/trunk/) C++ Header · 0 lines ✨ Summary

This C++ header code defines a set of overloaded operators for an actor-based system, allowing for flexible and expressive programming. It provides various overloads for operator overloading, enabling the creation of complex actors with multiple inputs and outputs. The code is designed to work with the Phoenix library, which is used for building concurrent and parallel systems.

14

15 template <typename This, typename A0>

16 struct result<This(A0)>

17 : result<This(typename detail::result_type_deduction_helper<A0>::type)>

18 {};

19 template <typename This, typename A0> struct result<This(A0 &)> : result_of::actor<proto_base_expr, A0 &> {}; template <typename A0> typename result_of::actor<proto_base_expr, A0 &>::type operator()(A0 & a0) const { typedef vector2< const actor<Expr> *, A0 & > env_type; env_type env = {this, a0}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename A0> typename result_of::actor<proto_base_expr, A0 &>::type operator()(A0 & a0) { typedef vector2< const actor<Expr> *, A0 & > env_type; env_type env = {this, a0}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename This, typename A0> struct result<This(A0 const&)> : result_of::actor<proto_base_expr, A0 const&> {}; template <typename A0> typename result_of::actor<proto_base_expr, A0 const&>::type operator()(A0 const& a0) const { typedef vector2< const actor<Expr> *, A0 const& > env_type; env_type env = {this, a0}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename A0> typename result_of::actor<proto_base_expr, A0 const&>::type operator()(A0 const& a0) { typedef vector2< const actor<Expr> *, A0 const& > env_type; env_type env = {this, a0}; return phoenix::eval(*this, phoenix::context(env, default_actions())); }

20

21

26

27 template <typename This, typename A0 , typename A1>

28 struct result<This(A0 , A1)>

29 : result<This(typename detail::result_type_deduction_helper<A0>::type , typename detail::result_type_deduction_helper<A1>::type)>

30 {};

31 template <typename This, typename A0 , typename A1> struct result<This(A0 & , A1 &)> : result_of::actor<proto_base_expr, A0 & , A1 &> {}; template <typename A0 , typename A1> typename result_of::actor<proto_base_expr, A0 & , A1 &>::type operator()(A0 & a0 , A1 & a1) const { typedef vector3< const actor<Expr> *, A0 & , A1 & > env_type; env_type env = {this, a0 , a1}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename A0 , typename A1> typename result_of::actor<proto_base_expr, A0 & , A1 &>::type operator()(A0 & a0 , A1 & a1) { typedef vector3< const actor<Expr> *, A0 & , A1 & > env_type; env_type env = {this, a0 , a1}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename This, typename A0 , typename A1> struct result<This(A0 & , A1 const&)> : result_of::actor<proto_base_expr, A0 & , A1 const&> {}; template <typename A0 , typename A1> typename result_of::actor<proto_base_expr, A0 & , A1 const&>::type operator()(A0 & a0 , A1 const& a1) const { typedef vector3< const actor<Expr> *, A0 & , A1 const& > env_type; env_type env = {this, a0 , a1}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename A0 , typename A1> typename result_of::actor<proto_base_expr, A0 & , A1 const&>::type operator()(A0 & a0 , A1 const& a1) { typedef vector3< const actor<Expr> *, A0 & , A1 const& > env_type; env_type env = {this, a0 , a1}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename This, typename A0 , typename A1> struct result<This(A0 const& , A1 &)> : result_of::actor<proto_base_expr, A0 const& , A1 &> {}; template <typename A0 , typename A1> typename result_of::actor<proto_base_expr, A0 const& , A1 &>::type operator()(A0 const& a0 , A1 & a1) const { typedef vector3< const actor<Expr> *, A0 const& , A1 & > env_type; env_type env = {this, a0 , a1}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename A0 , typename A1> typename result_of::actor<proto_base_expr, A0 const& , A1 &>::type operator()(A0 const& a0 , A1 & a1) { typedef vector3< const actor<Expr> *, A0 const& , A1 & > env_type; env_type env = {this, a0 , a1}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename This, typename A0 , typename A1> struct result<This(A0 const& , A1 const&)> : result_of::actor<proto_base_expr, A0 const& , A1 const&> {}; template <typename A0 , typename A1> typename result_of::actor<proto_base_expr, A0 const& , A1 const&>::type operator()(A0 const& a0 , A1 const& a1) const { typedef vector3< const actor<Expr> *, A0 const& , A1 const& > env_type; env_type env = {this, a0 , a1}; return phoenix::eval(*this, phoenix::context(env, default_actions())); } template <typename A0 , typename A1> typename result_of::actor<proto_base_expr, A0 const& , A1 const&>::type operator()(A0 const& a0 , A1 const& a1) { typedef vector3< const actor<Expr> *, A0 const& , A1 const& > env_type; env_type env = {this, a0 , a1}; return phoenix::eval(*this, phoenix::context(env, default_actions())); }

32

33

dist_nc_f_incl_test.cpp (http://hadesmem.googlecode.com/svn/trunk/) C++ · 0 lines ✨ Summary

This C++ code is a test for the non_central_f distribution header, ensuring that all necessary files are included and compiled correctly. It includes the header file itself, another test file, and template instantiations for different data types to verify compilation results. The purpose is to validate the correctness of the non_central_f distribution implementation.

12 // important if this test is to be meaningful:

13 //

14 #include "test_compile_result.hpp"

15

16 void compile_and_link_test()

nodeGen.cpp (git://github.com/ticking/self.git) C++ · 469 lines ✨ Summary

This C++ code is part of a compiler implementation, specifically responsible for generating branch instructions (if-else statements) in machine code. It creates nodes and merges them to represent conditional branches, allowing the compiler to decide which path to take based on the program’s logic. The generated code is optimized for performance and minimizes unnecessary operations.

27 nlrHomePR = new PReg(NULL, NLRHomeReg, true, true);

28 nlrHomeIDPR = new PReg(NULL, NLRHomeIDReg, true, true);

29 nlrResultPR = new PReg(NULL, NLRResultReg, true, true);

30 nlrTempPR = new PReg(NULL, NLRTempReg, true, true);

31 framePR = new PReg(NULL, FrameReg, true, true);

235 }

236

237 void NodeGen::prepareNLR(PReg* result, PReg* scope, smi homeID) {

238 Unused(scope);

239 // set up NLR registers

240 loadArg(result, nlrResultPR);

241 APPEND(new LoadIntNode(homeID, nlrHomeIDPR));

242 // (nlrHomePR is loaded by caller)

shuffle_output.hpp (http://hadesmem.googlecode.com/svn/trunk/) C++ Header · 0 lines ✨ Summary

This C++ header file defines a class shuffle_output that inherits from shuffle_order_engine. It provides a way to shuffle output from a random number generator, allowing for more control over the shuffling process. The class is designed to be used with Boost’s random number generation library and can be instantiated with different types of input ranges or single values.

25

26 template<typename URNG, int k,

27 typename URNG::result_type val = 0>

28 class shuffle_output : public shuffle_order_engine<URNG, k>

29 {

30 typedef shuffle_order_engine<URNG, k> base_t;

31 typedef typename base_t::result_type result_type;

32 public:

33 shuffle_output() {}

38 template<class It>

39 shuffle_output(It& first, It last) : base_t(first, last) {}

40 result_type min BOOST_PREVENT_MACRO_SUBSTITUTION ()

41 { return (this->base().min)(); }

42 result_type max BOOST_PREVENT_MACRO_SUBSTITUTION ()

qimage_sse2.cpp (https://bitbucket.org/ultra_iter/qt-vtl.git) C++ · 109 lines

82 alphaChannel = _mm_or_si128(alphaChannel, _mm_slli_epi32(alphaChannel, 16));

83

84 __m128i result;

85 BYTE_MUL_SSE2(result, srcVector, alphaChannel, colorMask, half);

86 result = _mm_or_si128(_mm_andnot_si128(alphaMask, result), srcVectorAlpha);

87 _mm_storeu_si128(d, result);

HyperSearch_Results_to_Buffer.bsh (https://jedit.svn.sourceforge.net/svnroot/jedit) Unknown · 86 lines

1 /*

2 * HyperSearch_Results_to_Buffer.bsh - a Beanshell macro

3 * for jEdit text that writes HyperSearch results

22 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.

23 *

24 * $Id: HyperSearch_Results_to_Buffer.bsh 4911 2003-11-12 00:24:11Z spestov $

25 */

26

27 writeHypersearchResultsToBuffer(View view){

28 hs = view.getDockableWindowManager().getDockableWindow("hypersearch-results");

29 if (hs == null)

30 {

31 Macros.error(view, "The 'HyperSearch Results' window is not open.");

32 return;

33 }

configure.in (https://bitbucket.org/ultra_iter/vim-qt.git) Autoconf · 3806 lines

37 [fail_if_missing="yes"],

38 [fail_if_missing="no"])

39 AC_MSG_RESULT($fail_if_missing)

40

41 dnl Set default value for CFLAGS if none is defined or it's empty

66 dnl wrong with the CC or CFLAGS settings, give a useful warning message

67 if test "$cross_compiling" = yes; then

68 AC_MSG_RESULT([cannot compile a simple program; if not cross compiling check CC and CFLAGS])

69 fi

70

911 PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\""

912 else

913 PYTHON_CFLAGS="-I${vi_cv_path_python_pfx}/include/python${vi_cv_var_python_version} -I${vi_cv_path_python_epfx}/include/python${vi_cv_var_python_version} -DPYTHON_HOME=\\\"${vi_cv_path_python_pfx}\\\""

914 fi

915 PYTHON_SRC="if_python.c"

OperatingSystem.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 362 lines ✨ Summary

This Java code defines a class that determines the operating system and Java version of the running application. It uses various methods to detect the OS, including checking system properties and file separators. The detected values are stored in instance variables for later use. The class can be used to customize behavior based on the detected environment.

269 else if(hasScreenMenuBar == -1)

270 {

271 String result = System.getProperty("apple.laf.useScreenMenuBar");

272 if (result == null)

273 result = System.getProperty("com.apple.macos.useScreenMenuBar");

274 hasScreenMenuBar = ("true".equals(result)) ? 1 : 0;

15.10.6.2-2.js (https://bitbucket.org/ultra_iter/qt-vtl.git) JavaScript · 367 lines

52 * 15.10.6.2 RegExp.prototype.exec(string)

53 * Performs a regular expression match of string against the regular

54 * expression and returns an Array object containing the results of

55 * the match, or null if the string did not match.

56 *

66 * 7. Call [[Match]], giving it the arguments S and i.

67 * If [[Match]] returned failure, go to step 8;

68 * otherwise let r be its State result and go to step 10.

69 * 8. Let i = i+1.

70 * 9. Go to step 6.

97 */

98 //-----------------------------------------------------------------------------

99 var gTestfile = '15.10.6.2-2.js';

100 var i = 0;

101 var BUGNUMBER = 76717;

102 var summary = 'Testing re.exec(str) when re.lastIndex is < 0 or > str.length';

CheckoutDialog.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 268 lines ✨ Summary

This Java code creates a graphical user interface (GUI) for a checkout dialog box, likely used in a version control system like Subversion. It allows users to input their SVN credentials and repository information, such as URL and directory path, before checking out files from the repository. The GUI includes fields for username, password, and repository details, with buttons for canceling or confirming the operation.

93 info_data.setPaths(info_path);

94 String url_text = null;

95 List<SVNInfo> info_results = null;

96 try {

97 info_results = new Info().getInfo(info_data);

100 info_results = null;

101 }

102 if (info_results != null && info_results.size() > 0) {

103 SVNInfo svn_info = info_results.get(0);

Info.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 242 lines ✨ Summary

This Java code outputs information about a file’s metadata, such as its last changed date, author, and checksum, when retrieved from a version control system like Subversion (SVN). It formats this data in a human-readable format, including timestamps and line counts for comments. The output is printed to the console, allowing users to view detailed information about the file’s history and changes.

60

61 public List<SVNInfo> info( SVNData data ) throws CommandInitializationException, SVNException {

62 List<SVNInfo> results = getInfo( data );

63

64 // print the results

65 for ( SVNInfo info : results ) {

66 handleInfo( info, data.getOut() );

67 }

106 SVNInfo result = client.doInfo( svnurl, SVNRevision.HEAD, SVNRevision.HEAD );

107 results.add( result );

108 }

109 }

113 SVNInfo result = client.doInfo( localPath, SVNRevision.HEAD );

114 results.add( result );

115 }

116 }

UnixFileSystem.php (git://github.com/alexgorbatchev/SyntaxHighlighter.git) text · 0 lines

146 /**

147 * Resolve the child pathname string against the parent.

148 * Both strings must be in normal form, and the result

149 * will be in normal form.

150 */

runner.js (http://enginey.googlecode.com/svn/trunk/) JavaScript · 1054 lines ✨ Summary

This JavaScript code initializes and runs the Dojo Unit Test Harness, a testing framework for Dojo, a JavaScript library. It loads required modules, sets up test runners, and executes tests when loaded as part of a larger application. The code is designed to work in various environments, including browsers and Rhino (a JavaScript engine).

17

18 doh.hitch = function(/*Object*/thisObject, /*Function|String*/method /*, ...*/){

19 var args = [];

20 for(var x=2; x<arguments.length; x++){

21 args.push(arguments[x]);

22 }

23 var fcn = ((typeof method == "string") ? thisObject[method] : method) || function(){};

24 return function(){

25 var ta = args.concat([]); // make a copy

265 var fired = this.fired;

266 var res = this.results[fired];

267 var self = this;

539 runTest: (function(test){

540 return function(t){

541 var r = docTest.runTest(test.commands, test.expectedResult);

542 t.assertTrue(r.success);

543 }

BoyerMooreSearchMatcher.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 317 lines ✨ Summary

This Java code implements a Boyer-Moore string searching algorithm, which efficiently searches for a pattern within a larger text. It uses a skip table to determine how many characters can be skipped when a mismatch occurs during the search process. The code provides a BoyerMooreSearchMatcher class that encapsulates the algorithm and its parameters, allowing for efficient and optimized string matching.

127 } //}}}

128

129 // position variable for pattern test position

130 int pos;

131

132 // position variable for pattern start

133 int anchor = 0;

134

243 * to avoid our skip table having a length of 2 ^ 16, we hash each

244 * character of the input into a character in the alphabet [\x00-\xFF]

245 * using the lower 8 bits of the character's value (resulting in

246 * a more reasonable skip table of length 2 ^ 8).

247 *

FacetFinderImpl.java (https://bitbucket.org/nbargnesi/idea.git) Java · 149 lines

67 if (cachedValue == null) {

68 cachedValue = myCachedValuesManager.createCachedValue(new CachedValueProvider<Map<VirtualFile, List<Facet>>>() {

69 public Result<Map<VirtualFile, List<Facet>>> compute() {

70 Map<VirtualFile, List<Facet>> map = computeRootToFacetsMap(type);

71 return Result.create(map, getAllFacetsOfTypeModificationTracker(type));

sforce.180.apex.wsdl (http://forceworkbench.googlecode.com/svn/trunk/workbench/) Unknown · 572 lines

52 <xsd:element name="deleteTriggers" minOccurs="0" maxOccurs="unbounded" type="tns:DeleteApexResult"/>

53 <xsd:element name="runTestsResult" type="tns:RunTestsResult"/>

54 <xsd:element name="success" type="xsd:boolean"/>

55

347 <xsd:complexType>

348 <xsd:sequence>

349 <xsd:element name="result" type="tns:ExecuteAnonymousResult"/>

350 </xsd:sequence>

351 </xsd:complexType>

362 <xsd:complexType>

363 <xsd:sequence>

364 <xsd:element name="result" type="tns:RunTestsResult"/>

365

366 </xsd:sequence>

378 <xsd:complexType>

379 <xsd:sequence>

380 <xsd:element name="result" type="tns:WsdlToApexResult"/>

381 </xsd:sequence>

382 </xsd:complexType>

KeymapImpl.java (https://bitbucket.org/nbargnesi/idea.git) Java · 908 lines

831

832 public HashMap<String, ArrayList<KeyboardShortcut>> getConflicts(String actionId, KeyboardShortcut keyboardShortcut) {

833 HashMap<String, ArrayList<KeyboardShortcut>> result = new HashMap<String, ArrayList<KeyboardShortcut>>();

834

835 String[] actionIds = getActionIds(keyboardShortcut.getFirstKeyStroke());

869 }

870

871 ArrayList<KeyboardShortcut> list = result.get(id);

872 if (list == null) {

873 list = new ArrayList<KeyboardShortcut>();

874 result.put(id, list);

875 }

876

IURIResolver.as (http://flowplayer-core.googlecode.com/svn/) ActionScript · 79 lines ✨ Summary

This ActionScript code defines an interface IURIResolver that provides a custom URI resolution mechanism for the URI class. It allows applications to resolve DNS aliases, virtual hosts, and symbolic links before comparing URIs. The interface has a single method resolve(uri:URI) : URI that returns a resolved URI.

17 You agree to indemnify, hold harmless and defend Adobe Systems Incorporated from and

18 against any loss, damage, claims or lawsuits, including attorney's

19 fees that arise or result from your use or distribution of the source

20 code.

21

jEdit.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 4373 lines ✨ Summary

This Java code is part of a text editor application, managing views and user interactions. It handles view creation, closing, and switching between views. It also manages settings, garbage collection, and memory usage. The code provides methods for getting and setting various properties, such as the number of open views, the currently active view, and whether jEdit is running in background mode.

463 KillRing.setInstance(new JEditKillRing());

464 KillRing.getInstance().load();

465 GUIUtilities.advanceSplashProgress("init various properties");

466 propertiesChanged();

467

529 try

530 {

531 BeanShell.getNameSpace().setVariable("args",args);

532 }

533 catch(UtilEvalError e)

912 //{{{ propertiesChanged() method

913 /**

914 * Reloads various settings from the properties.

915 */

916 public static void propertiesChanged()

15.9.5.37-4.js (https://bitbucket.org/ultra_iter/qt-vtl.git) JavaScript · 163 lines

54 4. If date is not specified, compute DateFromTime(t); otherwise, call

55 ToNumber(date).

56 5. Compute MakeDay(Result(2), Result(3), Result(4)).

57 6. Compute MakeDate(Result(5), TimeWithinDay(t)).

58 7. Set the [[Value]] property of the this value to TimeClip(Result(6)).

59 8. Return the value of the [[Value]] property of the this value.

60

64 Added some Year 2000 test cases.

65 */

66 var SECTION = "15.9.5.37-1";

67 var VERSION = "ECMA_1";

138 }

139 function MyDateFromTime( t ) {

140 var d = new MyDate();

141 d.year = YearFromTime(t);

142 d.month = MonthFromTime(t);

XMLHttpRequest.cpp (https://bitbucket.org/ultra_iter/qt-vtl.git) C++ · 1131 lines

166 static const XMLHttpRequestStaticData* initializeXMLHttpRequestStaticData()

167 {

168 // Uses dummy to avoid warnings about an unused variable.

169 AtomicallyInitializedStatic(const XMLHttpRequestStaticData*, dummy = createXMLHttpRequestStaticData());

170 return dummy;

832 void XMLHttpRequest::setRequestHeaderInternal(const AtomicString& name, const String& value)

833 {

834 pair<HTTPHeaderMap::iterator, bool> result = m_requestHeaders.add(name, value);

835 if (!result.second)

836 result.first->second += ", " + value;

837 }

838

15.8.2.1.js (https://bitbucket.org/ultra_iter/qt-vtl.git) JavaScript · 226 lines

46 with a positive sign.

47 - if x is NaN, return NaN

48 - if x is -0, result is +0

49 - if x is -Infinity, result is +Infinity

51 Date: 7 july 1997

52 */

53 var SECTION = "15.8.2.1";

54 var VERSION = "ECMA_1";

55 var TITLE = "Math.abs()";

56 var BUGNUMBER = "77391";

SearchAndReplace.java (https://jedit.svn.sourceforge.net/svnroot/jedit) Java · 1392 lines ✨ Summary

This Java code is part of a text replacement engine, likely used for editing and formatting text. It provides methods to replace occurrences of a search string with a replacement string, using various replacement strategies such as regular expressions, literal strings, and BeanShell scripting. The code also handles cases like case sensitivity, line breaks, and column offsets.

378 HyperSearchResults.NAME);

379 final HyperSearchResults results = (HyperSearchResults)

380 view.getDockableWindowManager()

381 .getDockable(HyperSearchResults.NAME);

382 results.searchStarted();

383

384 try

388 {

389 view.getToolkit().beep();

390 results.searchFailed();

391 return false;

392 }

398 if(s == null)

399 {

400 results.searchFailed();

401 return false;

402 }