1
|
{"version":3,"sources":["webpack:///./node_modules/highlight.js/lib/languages/swift.js"],"names":["module","exports","hljs","SWIFT_KEYWORDS","keyword","literal","built_in","BLOCK_COMMENT","COMMENT","contains","SUBST","className","begin","end","keywords","STRING","BACKSLASH_ESCAPE","variants","NUMBERS","relevance","C_LINE_COMMENT_MODE","beginKeywords","excludeEnd","inherit","TITLE_MODE","endsParent","C_BLOCK_COMMENT_MODE","illegal"],"mappings":"6EAAAA,EAAAC,QAAA,SAAAC,GACA,IAAAC,EAAA,CACAC,QAAA,gvBAUAC,QAAA,iBACAC,SAAA,+kCA2BAC,EAAAL,EAAAM,QACA,OACA,OACA,CACAC,SAAA,WAGAC,EAAA,CACAC,UAAA,QACAC,MAAA,OAAAC,IAAA,MACAC,SAAAX,EACAM,SAAA,IAEAM,EAAA,CACAJ,UAAA,SACAF,SAAA,CAAAP,EAAAc,iBAAAN,GACAO,SAAA,CACA,CAAOL,MAAA,MAAAC,IAAA,OACP,CAAOD,MAAA,IAAAC,IAAA,OAGPK,EAAA,CACAP,UAAA,SACAC,MAAA,wFACAO,UAAA,GAIA,OAFAT,EAAAD,SAAA,CAAAS,GAEA,CACAJ,SAAAX,EACAM,SAAA,CACAM,EACAb,EAAAkB,oBACAb,EArCA,CACAI,UAAA,OACAC,MAAA,0BARA,CACAD,UAAA,OACAC,MAAA,qBACAO,UAAA,GA2CAD,EACA,CACAP,UAAA,WACAU,cAAA,OAAAR,IAAA,IAAsCS,YAAA,EACtCb,SAAA,CACAP,EAAAqB,QAAArB,EAAAsB,WAAA,CACAZ,MAAA,6BAEA,CACAA,MAAA,IAAAC,IAAA,KAEA,CACAF,UAAA,SACAC,MAAA,KAAAC,IAAA,KAAAY,YAAA,EACAX,SAAAX,EACAM,SAAA,CACA,OACAS,EACAH,EACAb,EAAAwB,qBACA,CAAed,MAAA,MAEfe,QAAA,SAGAA,QAAA,QAEA,CACAhB,UAAA,QACAU,cAAA,uCACAP,SAAAX,EACAU,IAAA,MACAS,YAAA,EACAb,SAAA,CACAP,EAAAqB,QAAArB,EAAAsB,WAAA,CAAyCZ,MAAA,4CAGzC,CACAD,UAAA,OACAC,MAAA,ySAOA,CACAS,cAAA,SAAAR,IAAA,IACAJ,SAAA,CAAAP,EAAAkB,oBAAAb","file":"highlight/swift.js?v=1a1fa63e17d8a101c1bf","sourcesContent":["module.exports = function(hljs) {\n var SWIFT_KEYWORDS = {\n keyword: '#available #colorLiteral #column #else #elseif #endif #file ' +\n '#fileLiteral #function #if #imageLiteral #line #selector #sourceLocation ' +\n '_ __COLUMN__ __FILE__ __FUNCTION__ __LINE__ Any as as! as? associatedtype ' +\n 'associativity break case catch class continue convenience default defer deinit didSet do ' +\n 'dynamic dynamicType else enum extension fallthrough false fileprivate final for func ' +\n 'get guard if import in indirect infix init inout internal is lazy left let ' +\n 'mutating nil none nonmutating open operator optional override postfix precedence ' +\n 'prefix private protocol Protocol public repeat required rethrows return ' +\n 'right self Self set static struct subscript super switch throw throws true ' +\n 'try try! try? Type typealias unowned var weak where while willSet',\n literal: 'true false nil',\n built_in: 'abs advance alignof alignofValue anyGenerator assert assertionFailure ' +\n 'bridgeFromObjectiveC bridgeFromObjectiveCUnconditional bridgeToObjectiveC ' +\n 'bridgeToObjectiveCUnconditional c contains count countElements countLeadingZeros ' +\n 'debugPrint debugPrintln distance dropFirst dropLast dump encodeBitsAsWords ' +\n 'enumerate equal fatalError filter find getBridgedObjectiveCType getVaList ' +\n 'indices insertionSort isBridgedToObjectiveC isBridgedVerbatimToObjectiveC ' +\n 'isUniquelyReferenced isUniquelyReferencedNonObjC join lazy lexicographicalCompare ' +\n 'map max maxElement min minElement numericCast overlaps partition posix ' +\n 'precondition preconditionFailure print println quickSort readLine reduce reflect ' +\n 'reinterpretCast reverse roundUpToAlignment sizeof sizeofValue sort split ' +\n 'startsWith stride strideof strideofValue swap toString transcode ' +\n 'underestimateCount unsafeAddressOf unsafeBitCast unsafeDowncast unsafeUnwrap ' +\n 'unsafeReflect withExtendedLifetime withObjectAtPlusZero withUnsafePointer ' +\n 'withUnsafePointerToObject withUnsafeMutablePointer withUnsafeMutablePointers ' +\n 'withUnsafePointer withUnsafePointers withVaList zip'\n };\n\n var TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][\\\\w\\u00C0-\\u02B8\\']*',\n relevance: 0\n };\n // slightly more special to swift\n var OPTIONAL_USING_TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][\\\\w\\u00C0-\\u02B8\\']*[!?]'\n }\n var BLOCK_COMMENT = hljs.COMMENT(\n '/\\\\*',\n '\\\\*/',\n {\n contains: ['self']\n }\n );\n var SUBST = {\n className: 'subst',\n begin: /\\\\\\(/, end: '\\\\)',\n keywords: SWIFT_KEYWORDS,\n contains: [] // assigned later\n };\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: /\"\"\"/, end: /\"\"\"/},\n {begin: /\"/, end: /\"/},\n ]\n };\n var NUMBERS = {\n className: 'number',\n begin: '\\\\b([\\\\d_]+(\\\\.[\\\\deE_]+)?|0x[a-fA-F0-9_]+(\\\\.[a-fA-F0-9p_]+)?|0b[01_]+|0o[0-7_]+)\\\\b',\n relevance: 0\n };\n SUBST.contains = [NUMBERS];\n\n return {\n keywords: SWIFT_KEYWORDS,\n contains: [\n STRING,\n hljs.C_LINE_COMMENT_MODE,\n BLOCK_COMMENT,\n OPTIONAL_USING_TYPE,\n TYPE,\n NUMBERS,\n {\n className: 'function',\n beginKeywords: 'func', end: '{', excludeEnd: true,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {\n begin: /[A-Za-z$_][0-9A-Za-z$_]*/\n }),\n {\n begin: /</, end: />/\n },\n {\n className: 'params',\n begin: /\\(/, end: /\\)/, endsParent: true,\n keywords: SWIFT_KEYWORDS,\n contains: [\n 'self',\n NUMBERS,\n STRING,\n hljs.C_BLOCK_COMMENT_MODE,\n {begin: ':'} // relevance booster\n ],\n illegal: /[\"']/\n }\n ],\n illegal: /\\[|%/\n },\n {\n className: 'class',\n beginKeywords: 'struct protocol class extension enum',\n keywords: SWIFT_KEYWORDS,\n end: '\\\\{',\n excludeEnd: true,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: /[A-Za-z$_][\\u00C0-\\u02B80-9A-Za-z$_]*/})\n ]\n },\n {\n className: 'meta', // @attributes\n begin: '(@discardableResult|@warn_unused_result|@exported|@lazy|@noescape|' +\n '@NSCopying|@NSManaged|@objc|@objcMembers|@convention|@required|' +\n '@noreturn|@IBAction|@IBDesignable|@IBInspectable|@IBOutlet|' +\n '@infix|@prefix|@postfix|@autoclosure|@testable|@available|' +\n '@nonobjc|@NSApplicationMain|@UIApplicationMain)'\n\n },\n {\n beginKeywords: 'import', end: /$/,\n contains: [hljs.C_LINE_COMMENT_MODE, BLOCK_COMMENT]\n }\n ]\n };\n};"],"sourceRoot":""}
|