mirror of
				https://github.com/ethereum/solidity
				synced 2023-10-03 13:03:40 +00:00 
			
		
		
		
	
		
			
				
	
	
		
			23 lines
		
	
	
		
			541 B
		
	
	
	
		
			Solidity
		
	
	
	
	
	
			
		
		
	
	
			23 lines
		
	
	
		
			541 B
		
	
	
	
		
			Solidity
		
	
	
	
	
	
| contract test {
 | |
|     function oneByteUTF8() public pure returns (bytes32) {
 | |
|         bytes32 usdollar = "aaa\u0024aaa";
 | |
|         return usdollar;
 | |
|     }
 | |
| 
 | |
|     function twoBytesUTF8() public pure returns (bytes32) {
 | |
|         bytes32 cent = "aaa\u00A2aaa";
 | |
|         return cent;
 | |
|     }
 | |
| 
 | |
|     function threeBytesUTF8() public pure returns (bytes32) {
 | |
|         bytes32 eur = "aaa\u20ACaaa";
 | |
|         return  eur;
 | |
|     }
 | |
| 
 | |
|     function combined() public pure returns (bytes32) {
 | |
|         bytes32 res = "\u0024\u00A2\u20AC";
 | |
|         return res;
 | |
|     }
 | |
| }
 | |
| // ----
 |