diff --git a/Dictionary.cls b/Dictionary.cls index ffffcff..65a324b 100644 --- a/Dictionary.cls +++ b/Dictionary.cls @@ -8,7 +8,7 @@ Attribute VB_Creatable = False Attribute VB_PredeclaredId = False Attribute VB_Exposed = True '' -' Dictionary v1.1.1 +' Dictionary v1.2.0 ' (c) Tim Hall - https://github.com/timhall/VBA-Dictionary ' ' Drop-in replacement for Scripting.Dictionary on Mac @@ -23,7 +23,7 @@ Option Explicit ' Constants and Private Variables ' --------------------------------------------- ' -#Const UseScriptingDictionaryIfAvailable = False +#Const UseScriptingDictionaryIfAvailable = True #If Mac Or Not UseScriptingDictionaryIfAvailable Then diff --git a/readme.md b/readme.md index f0075b4..362296c 100644 --- a/readme.md +++ b/readme.md @@ -1,6 +1,6 @@ # VBA-Dictionary -VBA-Dictionary is a drop-in replacement for the useful and powerful `Scripting.Dictionary` on Mac. It is designed to be a precise replacement to `Scripting.Dictionary` including `Item` as the default property (`Dict("A") = Dict.Item("A")`), matching error codes, and matching methods and properties. If you find any implementation differences between `Scripting.Dictionary` and VBA-Dictionary, please [create an issue](https://github.com/timhall/VBA-Dictionary/issues/new). +VBA-Dictionary is a drop-in replacement for the useful and powerful `Scripting.Dictionary` so that it can be used with both Mac and Windows. It is designed to be a precise replacement to `Scripting.Dictionary` including `Item` as the default property (`Dict("A") = Dict.Item("A")`), matching error codes, and matching methods and properties. If you find any implementation differences between `Scripting.Dictionary` and VBA-Dictionary, please [create an issue](https://github.com/timhall/VBA-Dictionary/issues/new). ## Example @@ -47,6 +47,10 @@ Dict("C") ' -> Empty ### Release Notes +#### 1.2.0 + +- Improve compatibility for empty Dictionary (`UBound` for empty `Keys` and `Items` is `-1` and can `For Each` over empty `Keys` and `Items`, matching `Scripting.Dictionary`) + #### 1.1.0 - Use compiler statements to use Scripting.Dictionary internally if available (improves Windows performance by ~3x) diff --git a/specs/VBA-Dictionary - Specs.xlsm b/specs/VBA-Dictionary - Specs.xlsm index c9042b2..393d8a6 100644 Binary files a/specs/VBA-Dictionary - Specs.xlsm and b/specs/VBA-Dictionary - Specs.xlsm differ